Class: Yuki::Animation::TimedCommands
- Inherits:
-
DiscreetAnimation
- Object
- TimedAnimation
- DiscreetAnimation
- Yuki::Animation::TimedCommands
- Defined in:
- docs/4_Systems_005_Animation.rb
Overview
Note:
It’ll skip all the commands that are not SpriteCreationCommand if it’s “too late”
Animation that try to execute all the given command at total_time / n_command * command_index Example :
TimedCommands.new(1,
create_sprite(:main, :star1, SpriteSheet, [1, 3], [:select, 0, 0]),
send_command_to(:star1, :select, 0, 1),
send_command_to(:star1, :select, 0, 2),
)
# Will create the start at 0
# Will set the second cell at 0.33
# Will set the third cell at 0.66
Instance Attribute Summary
Attributes inherited from TimedAnimation
#begin_time, #end_time, #parallel_animations, #root, #sub_animation, #time_source
Instance Method Summary collapse
-
#initialize(time_to_process, *animation_commands) ⇒ TimedCommands
constructor
Create a new TimedCommands object.
-
#resolver=(resolver)
Define the resolver (and transmit it to all the childs / parallel).
-
#start(begin_offset = 0)
Start the animation (initialize it).
Methods inherited from TimedAnimation
#done?, #in_parallel_of, #parallel_add, #play_before, #update
Constructor Details
#initialize(time_to_process, *animation_commands) ⇒ TimedCommands
Create a new TimedCommands object
506 507 |
# File 'docs/4_Systems_005_Animation.rb', line 506 def initialize(time_to_process, *animation_commands) end |
Instance Method Details
#resolver=(resolver)
Define the resolver (and transmit it to all the childs / parallel)
514 515 |
# File 'docs/4_Systems_005_Animation.rb', line 514 def resolver=(resolver) end |
#start(begin_offset = 0)
Start the animation (initialize it)
510 511 |
# File 'docs/4_Systems_005_Animation.rb', line 510 def start(begin_offset = 0) end |