Method: Game#draw

Defined in:
lib/fantasy/loop.rb

#drawObject



73
74
75
76
77
78
79
80
81
82
83
84
# File 'lib/fantasy/loop.rb', line 73

def draw
  Gosu.draw_rect(0, 0, Global.screen_width, Global.screen_height, Global.background)

  (
    Global.backgrounds +
    Global.tile_maps +
    Global.actors +
    Global.hud_texts +
    Global.hud_images +
    Global.shapes
  ).sort_by(&:layer).each(&:draw)
end