Class: UI::Storage::ModeSprite
- Inherits:
-
SpriteSheet
- Object
- LiteRGSS::Disposable
- LiteRGSS::Drawable
- LiteRGSS::Sprite
- LiteRGSS::ShaderedSprite
- Sprite
- ShaderedSprite
- SpriteSheet
- UI::Storage::ModeSprite
- Defined in:
- scripts/01450 Systems/00200 Storage/00002 UI_Storage/00001 ModeSprite.rb
Overview
Sprite showing the current box mode
Constant Summary collapse
- SHEET_INDEXES =
List of sheet index for all modes
{ pokemon: 3, item: 4, battle: 6, box: 5 }
- SHEET_SIZE =
Constant telling how much section there's in the sprite
[1, 7]
Instance Attribute Summary collapse
-
#mode ⇒ Symbol
Get the mode.
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
-
#initialize(viewport, mode_handler) ⇒ ModeSprite
constructor
Create a new ModeSprite.
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, mode_handler) ⇒ ModeSprite
Create a new ModeSprite
16 17 18 19 20 21 |
# File 'scripts/01450 Systems/00200 Storage/00002 UI_Storage/00001 ModeSprite.rb', line 16 def initialize(, mode_handler) super(, *SHEET_SIZE) load_texture mode_handler.add_mode_ui(self) position_sprite end |
Instance Attribute Details
#mode ⇒ Symbol
Get the mode
8 9 10 |
# File 'scripts/01450 Systems/00200 Storage/00002 UI_Storage/00001 ModeSprite.rb', line 8 def mode @mode end |