This file contains hidden or 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
function PitBoss() { | |
this.version = function() { | |
return '0.0.0.0.0.1'; | |
}; | |
this.craps = function() { | |
return('<html><body>CRAP(S)! ver#' + version() + '</body></html>'); | |
}; | |
} | |
function TableTalk() { |
This file contains hidden or 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
// Prototypal | |
function House(){}; | |
House.prototype = { | |
edge: function() { | |
return 0.0136; | |
}, | |
fixedOdds: function() { | |
return true; | |
} | |
}; |
This file contains hidden or 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
http://en.wikipedia.org/wiki/File:Casino_Atari_cover.jpg |
This file contains hidden or 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
function Player() { | |
this.totalChips = 0.0; | |
} | |
Player.prototype.chipCount = function() { |
This file contains hidden or 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
function Player() { | |
this.totalChips = 0.0; | |
} | |
Player.prototype.chipCount = function() { | |
return this.totalChips; | |
}; | |
module.exports = Player; |
This file contains hidden or 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
var pitBoss = require('pit_boss'); | |
// How about... | |
pitBoss.listen(29999); | |
// Or... | |
pitBoss.set(port: 29999).start(); | |
// Getting worse... | |
pitBoss.set(port: 29999, tables: 4).onDone(function() { alert('oh noes'); }).start(); |
This file contains hidden or 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
alias brake="bundle exec rake $1" |
This file contains hidden or 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
def revoke(user) | |
proxy_association.owner.tap do |project| | |
# You can't remove the last user with access (someone has to have access to the project!) | |
if project.users.many? | |
if user.pending? && user.projects.one? | |
user.destroy | |
else | |
project.users.delete(user) | |
user.touch | |
end |
This file contains hidden or 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
vows = require 'vows' | |
assert = require 'assert' | |
cb = (callback) -> | |
setTimeout -> | |
callback(null, 'callback') | |
, 2000 | |
andWaitForCallback = undefined |