class RubyMan::MenuRubyMan

RubyMan object for decorating main menu

Public Instance Methods

created() click to toggle source
# File lib/ruby_man/GameObjects/menu.rb, line 7
def created
  self.sprite = Sprite['rubyman']
  set_pos(-4, 8)
  change_direction(Direction.right)
  @speed = 3
  @image_speed = 3
end
grid_step() click to toggle source
# File lib/ruby_man/GameObjects/menu.rb, line 15
def grid_step
  if @direction == Direction.right
    change_direction(Direction.left) if @grid_x >= 31
  else
    change_direction(Direction.right) if @grid_x <= -4
  end
end