This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rooms: | |
Auditorium: | |
starter: true | |
description: Panic fills the air instead of ideas. What's left of the Keynote Speaker rests in a shimmering puddle. | |
items: | |
Slag Heap: | |
look: Eyebeamed to death by a beholder. And right as he was about to crack the Keynesian foundations of 1970s Korean shipbuilding. | |
paths: | |
East: Lounge | |
Lounge: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
talk: | |
message: What do you want? | |
children: | |
- message: I'd like a snocone. | |
children: | |
- message: Here you go, friend. | |
after: giveSnocone | |
- message: How about the phone number for a beholder hunter? | |
children: | |
- message: Last beholder hunter left town years ago. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "What are you doing here? Do you have clearance to pick apples in this orchard?", | |
"children": [ | |
{ | |
"name": "Yes", | |
"children": [ | |
{ | |
"name": "Let's see some ID.", | |
"exitEvent": "checkID" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# metakoans.rb is an arduous set of exercises designed to stretch | |
# meta-programming muscle. the focus is on a single method 'attribute' which | |
# behaves much like the built-in 'attr', but whose properties require delving | |
# deep into the depths of meta-ruby. usage of the 'attribute' method follows | |
# the general form of | |
# | |
# class C | |
# attribute 'a' | |
# end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 4<w<8, 1<y<10, x and z are 6-sided dice. | |
HOW_MANY = 100000 | |
def range_rand(min,max) | |
min + rand(max-min) | |
end | |
def test_it | |
w = range_rand(4,8) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*-------- Here's how your Gists render in #newtwitter's details pane --------*/ | |
twttr.mediaType('twttr.media.types.Gist') | |
.url('http://gist.github.com') | |
.matcher(/\b(?:https?\:\/\/)?gist\.github\.com\/(\S+)/g) | |
.icon('generic') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "twitter" | |
myname = "hoverbird" | |
pw = "secretpasswordhere" | |
auth = Twitter::HTTPAuth.new(myname, pw) | |
t = Twitter::Base.new(auth) | |
# If your client (stored in the variable t) is connected, this should work | |
me = t.user(myname) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'rubygems' | |
require 'pp' | |
require 'irb/completion' | |
require 'irb/ext/save-history' | |
ARGV.concat [ "--readline", "--prompt-mode", "simple" ] | |
IRB.conf[:SAVE_HISTORY] = 100 | |
IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb-save-history" | |
IRB.conf[:AUTO_INDENT] = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> This is a Quix Command File | |
> | |
> For the syntax of this file, please refer to http://quixapp.com/syntax/ | |
> | |
@hoverbird's extra commands | |
rl javascript:function%20iprl5(){var%20d=document,z=d.createElement('scr'+'ipt'),b=d.body,l=d.location;try{if(!b)throw(0);d.title='(Saving...)%20'+d.title;z.setAttribute('src',l.protocol+'//www.instapaper.com/j/vivorXYWdEDu?u='+encodeURIComponent(l.href)+'&t='+(new%20Date().getTime()));b.appendChild(z);}catch(e){alert('Please%20wait%20until%20the%20page%20has%20loaded.');}}iprl5();void(0) Read Later with Instapaper | |
ip http://www.instapaper.com/u Instapaper |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Hash | |
def keeping(keys = []) | |
raise 'Please specify at least one key!' if keys.empty? | |
strkeys = keys.collect {|k| k.to_s} | |
self.clone.delete_if {|k,v| !strkeys.include?(k.to_s)} | |
end | |
end | |
# Tests! | |
h = {:kyle => 'Bragger', :patrick => 'Ewing'} |