johm / automatic_insurrection

combinatorics for social war
http://objectivechance.com/automatic_insurrection
26 stars 6 forks source link

Update for current versions of Sinatra, and simplify implementation by using core objects directly #3

Closed Empact closed 10 years ago

Empact commented 11 years ago

Enjoyed this script of yours, and made a few fixes:

Note I'm using some ruby 1.9.3 constructs here (e.g. hash keys, #sample), so this breaks backwards compatibility for the 1.8 folks.

johm commented 10 years ago

Looks good, except in 57a7be7 sample doesn't pop elements off, so you run the risk of repeats.

Empact commented 10 years ago

Should be fixed now. :-)