Class: UI::MiningGame::Tool_Hit_Sprite
- Inherits:
-
Tool_Sprite
- Object
- LiteRGSS::Disposable
- LiteRGSS::Drawable
- LiteRGSS::Sprite
- LiteRGSS::ShaderedSprite
- Sprite
- ShaderedSprite
- SpriteSheet
- Tool_Sprite
- UI::MiningGame::Tool_Hit_Sprite
- Defined in:
- scripts/01450 Systems/08001 Mining Game/00030 UI_Mining_Game/00010 Tool_Hit_Sprite.rb
Overview
Class that describes the Tool_Hit_Sprite object
Instance Attribute Summary
Attributes inherited from Tool_Sprite
Attributes inherited from SpriteSheet
Attributes inherited from LiteRGSS::ShaderedSprite
Attributes inherited from LiteRGSS::Sprite
#__index__, #angle, #bitmap, #height, #mirror, #opacity, #ox, #oy, #src_rect, #viewport, #visible, #width, #x, #y, #z, #zoom, #zoom_x, #zoom_y
Instance Method Summary collapse
-
#change_image
Set the new image of the sheet.
-
#initialize(viewport) ⇒ Tool_Hit_Sprite
constructor
Create the Tool_Hit_Sprite.
-
#number_image_x ⇒ Integer
Number of images on the same line.
Methods inherited from Tool_Sprite
#add_to_x, #add_to_y, #change_tool, #new_frame, #sub_to_x, #sub_to_y
Methods inherited from SpriteSheet
Methods inherited from Sprite
#load, #mouse_in?, #set_origin_div, #set_rect, #set_rect_div, #set_z, #simple_mouse_in?, #translate_mouse_coords, #update
Methods inherited from LiteRGSS::Sprite
new, #set_origin, #set_position
Methods inherited from LiteRGSS::Disposable
Constructor Details
#initialize(viewport) ⇒ Tool_Hit_Sprite
Create the Tool_Hit_Sprite
8 9 10 |
# File 'scripts/01450 Systems/08001 Mining Game/00030 UI_Mining_Game/00010 Tool_Hit_Sprite.rb', line 8 def initialize() super() end |
Instance Method Details
#change_image
Set the new image of the sheet
19 20 21 |
# File 'scripts/01450 Systems/08001 Mining Game/00030 UI_Mining_Game/00010 Tool_Hit_Sprite.rb', line 19 def change_image set_bitmap("mining_game/#{tool}_anim", :interface) if GamePlay::MiningGame::TOOLS.include? tool end |
#number_image_x ⇒ Integer
Number of images on the same line
14 15 16 |
# File 'scripts/01450 Systems/08001 Mining Game/00030 UI_Mining_Game/00010 Tool_Hit_Sprite.rb', line 14 def number_image_x return 5 end |