I hereby claim:
- I am britg on github.
- I am britg (https://keybase.io/britg) on keybase.
- I have a public key ASD3eqHnvrmgfpG5_HFfEZCq5dxHggVV2kB9FyiKvZcC1Qo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
class Triplet | |
# Class methods | |
# these generate Triplet _instances_ | |
def self.up_to max | |
valid = [] | |
(1..max).each do |x| | |
y = x+1 | |
z = y+1 |
def possible_win_combo(board, combos) | |
combos.each do |combo| | |
multiple_x = board.select {|space,value| combo.include?(space) && value == 'X'} | |
if multiple_x.length == 2 | |
return combo if (board[combo[0]] != 'O' && board[combo[1]] != 'O' && board[combo[2]] != 'O') | |
end | |
end | |
nil #return not necessary, implicit | |
end |
class Player | |
def initialize | |
@health = 20 | |
@clear_behind = false | |
@wounded = false | |
end | |
def play_turn(warrior) | |
warrior_wounded?(warrior) |
Vector2 mousePos = Input.mousePosition; | |
if (lastMousePos.Equals(mousePos)) { | |
return; | |
} | |
lastMousePos = mousePos; | |
Ray ray = Camera.main.ScreenPointToRay(mousePos); | |
float dist; | |
Plane plane = new Plane(Vector3.up, Vector3.right, Vector3.down); | |
plane.Raycast(ray, out dist); | |
Vector3 worldPoint = Camera.main.ScreenToWorldPoint(new Vector3(mousePos.x, mousePos.y, dist)); |
namespace :deploy | |
task :quick do | |
run "cd #{current_path}; git pull origin #{branch}" | |
system("cap #{stage} deploy:restart") | |
end | |
end |
Apps | |
http://www.reflectionapp.com/ | |
http://flexibits.com/fantastical | |
http://cheddarapp.com | |
http://appifywp.com/ | |
http://www.mint.com | |
https://www.braintreepayments.com/ | |
https://codeclimate.com/ | |
https://cardspring.com/ | |
http://nezumiapp.com/ |
$('#bar').removeClass('new').addClass('activated'); |
class Player < ActiveRecord::Base | |
# ... | |
def skills | |
@skills ||= (Skill.where(:player_id => self.id).first || \ | |
Skill.create(:player_id => self.id)) | |
end | |
end |
/** | |
* touch for jQuery | |
* | |
* Copyright (c) 2008 Peter Schmalfeldt (ManifestInteractive.com) <manifestinteractive@gmail.com> | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* | |
* This program is distributed in the hope that it will be useful, |