Class: UI::Storage::Composition
- Inherits:
-
UI::SpriteStack
- Object
- UI::SpriteStack
- UI::Storage::Composition
- Defined in:
- docs/4_Systems_200_Storage.rb
Overview
Stack responsive of showing the full PC UI
Constant Summary collapse
- OFFSET_Y_CURSOR =
Y Offset of the cursor while inside of the box
[0, -1, -2, -3, -4, -5, -5, -4, -3, -2, -1, 0]
- OFFSET_Y_CURSOR_OUT_OF_THE_BOX =
Y Offset of the cursor while outside of the box
[15, 30, 63, 79, 111, 126]
Constants inherited from UI::SpriteStack
UI::SpriteStack::NO_INITIAL_IMAGE
Instance Attribute Summary collapse
-
#box_index ⇒ Integer
readonly
Get the current box index.
-
#cursor_handler ⇒ CursorHandler
readonly
Get the cursor object.
-
#mode_handler ⇒ ModeHandler
readonly
Get the mode handler.
-
#party ⇒ Array<PFM::Pokemon>
Get the party.
-
#selection_handler ⇒ SelectionHandler
readonly
Get the selection handler.
-
#storage ⇒ PFM::Storage
Get the storage object.
-
#summary ⇒ Summary
readonly
Get the summary object.
Attributes inherited from UI::SpriteStack
#animated, #data, #moving, #stack, #viewport, #x, #y
Instance Method Summary collapse
-
#animate_left_arrow(middle_animation = nil)
Start animation for left arrow.
-
#animate_right_arrow(middle_animation = nil)
Start animation for right arrow.
-
#done? ⇒ boolean
Tell if the animation is done.
-
#hovering_box_option? ⇒ Boolean
Tell if the box option is hovered.
-
#hovering_left_arrow? ⇒ Boolean
Tell if the left arrow is hovered.
-
#hovering_mode_indicator? ⇒ Boolean
Tell if the mouse hover the mode indicator.
-
#hovering_party_left_arrow? ⇒ Boolean
Tell if the left arrow of party stack is hovered.
-
#hovering_party_right_arrow? ⇒ Boolean
Tell if the right arrow of party stack is hovered.
-
#hovering_pokemon_sprite? ⇒ Boolean
Tell if the mouse is hovering a pokemon sprite & update cursor index in consequence.
-
#hovering_right_arrow? ⇒ Boolean
Tell if the right arrow is hovered.
-
#hovering_selection_mode_indicator? ⇒ Boolean
Tell if the mouse hover the selection mode indicator.
-
#initialize(viewport, mode, selection_mode) ⇒ Composition
constructor
Create a new Composition.
-
#update
Update the composition state.
Methods inherited from UI::SpriteStack
#[], #add_background, #add_line, #add_text, #anime, #anime_delta_set, #dispose, #each, #execute_anime, #move, #move_to, #opacity, #opacity=, #push, #push_sprite, #set_origin, #set_position, #simple_mouse_in?, #size, #stop_animation, #translate_mouse_coords, #update_animation, #update_position, #visible, #visible=, #with_cache, #with_font, #with_surface, #z, #z=
Constructor Details
#initialize(viewport, mode, selection_mode) ⇒ Composition
Create a new Composition
632 633 |
# File 'docs/4_Systems_200_Storage.rb', line 632 def initialize(, mode, selection_mode) end |
Instance Attribute Details
#box_index ⇒ Integer (readonly)
Get the current box index
614 615 616 |
# File 'docs/4_Systems_200_Storage.rb', line 614 def box_index @box_index end |
#cursor_handler ⇒ CursorHandler (readonly)
Get the cursor object
620 621 622 |
# File 'docs/4_Systems_200_Storage.rb', line 620 def cursor_handler @cursor_handler end |
#mode_handler ⇒ ModeHandler (readonly)
Get the mode handler
605 606 607 |
# File 'docs/4_Systems_200_Storage.rb', line 605 def mode_handler @mode_handler end |
#party ⇒ Array<PFM::Pokemon>
Get the party
608 609 610 |
# File 'docs/4_Systems_200_Storage.rb', line 608 def party @party end |
#selection_handler ⇒ SelectionHandler (readonly)
Get the selection handler
623 624 625 |
# File 'docs/4_Systems_200_Storage.rb', line 623 def selection_handler @selection_handler end |
#storage ⇒ PFM::Storage
Get the storage object
611 612 613 |
# File 'docs/4_Systems_200_Storage.rb', line 611 def storage @storage end |
#summary ⇒ Summary (readonly)
Get the summary object
617 618 619 |
# File 'docs/4_Systems_200_Storage.rb', line 617 def summary @summary end |
Instance Method Details
#animate_left_arrow(middle_animation = nil)
Start animation for left arrow
647 648 |
# File 'docs/4_Systems_200_Storage.rb', line 647 def animate_left_arrow(middle_animation = nil) end |
#animate_right_arrow(middle_animation = nil)
Start animation for right arrow
643 644 |
# File 'docs/4_Systems_200_Storage.rb', line 643 def animate_right_arrow(middle_animation = nil) end |
#done? ⇒ boolean
Tell if the animation is done
639 640 |
# File 'docs/4_Systems_200_Storage.rb', line 639 def done? end |
#hovering_box_option? ⇒ Boolean
Tell if the box option is hovered
671 672 |
# File 'docs/4_Systems_200_Storage.rb', line 671 def hovering_box_option? end |
#hovering_left_arrow? ⇒ Boolean
Tell if the left arrow is hovered
679 680 |
# File 'docs/4_Systems_200_Storage.rb', line 679 def hovering_left_arrow? end |
#hovering_mode_indicator? ⇒ Boolean
Tell if the mouse hover the mode indicator
663 664 |
# File 'docs/4_Systems_200_Storage.rb', line 663 def hovering_mode_indicator? end |
#hovering_party_left_arrow? ⇒ Boolean
Tell if the left arrow of party stack is hovered
687 688 |
# File 'docs/4_Systems_200_Storage.rb', line 687 def hovering_party_left_arrow? end |
#hovering_party_right_arrow? ⇒ Boolean
Tell if the right arrow of party stack is hovered
683 684 |
# File 'docs/4_Systems_200_Storage.rb', line 683 def hovering_party_right_arrow? end |
#hovering_pokemon_sprite? ⇒ Boolean
Tell if the mouse is hovering a pokemon sprite & update cursor index in consequence
659 660 |
# File 'docs/4_Systems_200_Storage.rb', line 659 def hovering_pokemon_sprite? end |
#hovering_right_arrow? ⇒ Boolean
Tell if the right arrow is hovered
675 676 |
# File 'docs/4_Systems_200_Storage.rb', line 675 def hovering_right_arrow? end |
#hovering_selection_mode_indicator? ⇒ Boolean
Tell if the mouse hover the selection mode indicator
667 668 |
# File 'docs/4_Systems_200_Storage.rb', line 667 def hovering_selection_mode_indicator? end |
#update
Update the composition state
635 636 |
# File 'docs/4_Systems_200_Storage.rb', line 635 def update end |