0605
Jump to navigation
Jump to search
- Description
- Performs the animation on the character
- Syntax
- 0605: actor [char handle] perform_animation "[string1]" IFP "[string2]" framedelta [flt] loop [int1] lockX [int2] lockY [int3] lockF [int4] time [int5]
- Parameter
- [char handle]
- The handle of the character
- [string1]
- Animation sequence
- [string2]
- Animation file
- [flt]
- Rate of speed of animation (default 4.0)
- [int1]
- Allows animation to loop
- [int2]
- Allows character to remain at x-coordinate when animation ends
- [int3]
- Allows character to remain at y-coordinate when animation ends
- [int4]
- Locks character into last frame of animation
- [int5]
- Duration in milliseconds, -1 to allow animation to end by itself
This opcode makes the character perform the specified animation. With the exception of the "PED" animation file, using this opcode requires 04ED or else the game may crash.
Example
The following example using Sanny Builder allows a character to perform an animation.
0247: load_model #BFORI
04ED: load_animation "MISC"
038B: load_requested_models
009A: 0@ = create_actor_pedtype 5 model #BFORI at 0.0 0.0 0.0
0605: actor 0@ perform_animation_sequence "BMX_COMEON" IFP_file "MISC" 4.0 loop 0 lockX 0 lockY 0 lockF 0 time -1
0249: release_model #BFORI
04EF: release_animation "MISC"
Keywords
perform, animation, actor, character