Class: UI::Hall_of_Fame::Type_Background
- Inherits:
-
SpriteStack
- Object
- SpriteStack
- UI::Hall_of_Fame::Type_Background
- Defined in:
- scripts/01450 Systems/00300 Hall of fame/00002 UI/00001 Type_Background.rb
Overview
The class that define the type background displayed during phase 1
Constant Summary
Constants inherited from SpriteStack
Instance Attribute Summary collapse
-
#type_backgrounds ⇒ Array<Sprite>
The translucent backgrounds.
-
#type_foregrounds ⇒ Array<Sprite>
The non-translucent backgrounds.
Attributes inherited from SpriteStack
#animated, #data, #moving, #stack, #viewport, #x, #y
Instance Method Summary collapse
-
#initialize(viewport) ⇒ Type_Background
constructor
Initialize the SpriteStack.
Methods inherited from 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, #update_animation, #update_position, #visible, #visible=, #with_cache, #with_font, #with_surface, #z, #z=
Constructor Details
#initialize(viewport) ⇒ Type_Background
Initialize the SpriteStack
13 14 15 16 17 18 19 20 21 22 |
# File 'scripts/01450 Systems/00300 Hall of fame/00002 UI/00001 Type_Background.rb', line 13 def initialize() super() @type_backgrounds = Array.new($actors.size) { add_sprite(*foreground_pos, NO_INITIAL_IMAGE) } @type_foregrounds = Array.new($actors.size) { add_sprite(*foreground_pos, NO_INITIAL_IMAGE) } # pkm = [PFM::Pokemon] $actors.each_with_index do |pkm, index| @type_foregrounds[index].set_bitmap('hall_of_fame/' + pkm.type1.to_s, :interface).opacity = 0 @type_backgrounds[index].set_bitmap('hall_of_fame/' + pkm.type1.to_s, :interface).opacity = 0 end end |
Instance Attribute Details
#type_backgrounds ⇒ Array<Sprite>
The translucent backgrounds
10 11 12 |
# File 'scripts/01450 Systems/00300 Hall of fame/00002 UI/00001 Type_Background.rb', line 10 def type_backgrounds @type_backgrounds end |
#type_foregrounds ⇒ Array<Sprite>
The non-translucent backgrounds
7 8 9 |
# File 'scripts/01450 Systems/00300 Hall of fame/00002 UI/00001 Type_Background.rb', line 7 def type_foregrounds @type_foregrounds end |