Class: Endboss
- Inherits:
-
Object
- Object
- Endboss
- Defined in:
- lib/endboss.rb
Instance Method Summary collapse
- #draw ⇒ Object
-
#initialize(window) ⇒ Endboss
constructor
A new instance of Endboss.
Constructor Details
#initialize(window) ⇒ Endboss
Returns a new instance of Endboss.
3 4 5 6 7 8 |
# File 'lib/endboss.rb', line 3 def initialize(window) @image = Gosu::Image.new(window, 'media/endboss.png') @x = window.width/2 - @image.width/2 @y = window.height @scale = 0.0 end |
Instance Method Details
#draw ⇒ Object
10 11 12 13 |
# File 'lib/endboss.rb', line 10 def draw @scale += 0.03 if @scale <= 1 @image.draw(@x, @y - 750 * @scale, 3, @scale, @scale) end |