Class: GamesAndRpgParadise::Tetris::ShapeCube
- Defined in:
- lib/games_and_rpg_paradise/gui/gosu/tetris/shape_cube.rb
Instance Attribute Summary
Attributes inherited from Shape
Instance Method Summary collapse
-
#get_blocks ⇒ Object
# === get_blocks ========================================================================= #.
Methods inherited from Shape
#apply_rotation, #collide, #draw, #get_bounds, #initialize, #needs_fall_update?, #needs_move_update?, #reset_internal_variables, #reverse, #update
Constructor Details
This class inherits a constructor from GamesAndRpgParadise::Tetris::Shape
Instance Method Details
#get_blocks ⇒ Object
#
get_blocks
#
20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/games_and_rpg_paradise/gui/gosu/tetris/shape_cube.rb', line 20 def get_blocks @blocks[0].x = @x @blocks[1].x = @x @blocks[2].x = @x + @game.block_width @blocks[3].x = @x + @game.block_width @blocks[0].y = @y @blocks[1].y = @blocks[0].y + @game.block_height @blocks[2].y = @blocks[0].y @blocks[3].y = @blocks[2].y + @game.block_height @blocks.each { |block| block.color = 0xffffff00} end |