Skip to content

Instantly share code, notes, and snippets.

@webcrafts
Created November 5, 2013 11:18
Show Gist options
  • Save webcrafts/7317574 to your computer and use it in GitHub Desktop.
Save webcrafts/7317574 to your computer and use it in GitHub Desktop.
Ruby Warrior Level3
class Player
def play_turn(warrior)
# cool code goes here
if warrior.feel.empty? then
if warrior.health < 20 then
warrior.rest!
else
warrior.walk!
end
else
warrior.attack!
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment