Skip to content

Instantly share code, notes, and snippets.

@siegy22
Last active August 23, 2016 08:56
Show Gist options
  • Save siegy22/c547d4c421c20819431be29adf322c20 to your computer and use it in GitHub Desktop.
Save siegy22/c547d4c421c20819431be29adf322c20 to your computer and use it in GitHub Desktop.
require 'nintendo'
class Pingu < Nintendo::Character
def roll
move(:shield, :stick_left)
end
def attack
move(:stick_down, :attack)
end
def jeee
move(:stick_up, :special)
end
def die!
chügeli
puts "Nei kes chügeli"
super
end
def whop
move(:jump)
end
def chügeli
move(:stick_left, :special)
end
def hit_by(hit_score)
@percentage += hit_score
move(:off_platform)
end
end
ganondorf = Nintendo::Character::Ganondorf.new
dedede = Pingu.new
# FIGHT!
dedede.roll
dedede.chügeli
dedede.roll
dedede.attack
3.times do
dedede.roll
end
dedede.chügeli
dedede.hit_by(ganondorf.warlock_punch.hit_score)
5.times do
dedede.whop
end
dedede.die!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment