Skip to content

Instantly share code, notes, and snippets.

{
// Docs: http://play.elevatorsaga.com/documentation.html#docs
init: function(elevators, floors) {
console.log("init() with " + elevators.length + " elevators and " + floors.length + " floors");
for (var i=0; i<elevators.length; i++) {
(function(elevator){
elevator.on("idle", function() {
console.log("idle");
elevator.goToFloor(0);
//console.log("done idling");
class SiriProxy::Plugin::Twitter < SiriProxy::Plugin
# this watches when in the default context
listen_for /tweet (.*)/ do |data, tweetText|
show_rich_snippet do
image 'http://cl.ly/1l040J1A392n0M1n1g35/content' # this just makes things looks nice, but is obviously specific to my username
text tweetText
end
# this locks out other plugins until a confirmation or deny
confirm do
confirmed do