Finished rewrite of actor animation system
* Rewrote the actor animation system to work like sprites * Renamed a few functions * Added DeleteSpriteAnimation() and the delete queue to sprites * Removed transitions for the time being (they don't seem to work in irrlicht right now * Added PreUpdate() function * Added documentation for name changes and new functions
This commit is contained in:
6
doc/files/actoranimationisplaying.txt
Normal file
6
doc/files/actoranimationisplaying.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title ActorAnimationIsPlaying [RCBasic Doc]
|
||||
#header function ActorAnimationIsPlaying(actor)
|
||||
|
||||
Returns true if an actor is currently playing an animation
|
||||
|
||||
Note: If the number of loops in the animation is set to -1 then this will always be true since it does not return false until it plays the last frame in the last loop
|
||||
4
doc/files/createactoranimation.txt
Normal file
4
doc/files/createactoranimation.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
#title CreateActorAnimation [RCBasic Doc]
|
||||
#header Function CreateActorAnimation(actor, start_frame, end_frame, speed)
|
||||
|
||||
|
||||
10
doc/files/createanimatedactor.txt
Normal file
10
doc/files/createanimatedactor.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
#title CreateAnimatedActor [RCBasic Doc]
|
||||
#header function CreateAnimatedActor( mesh )
|
||||
|
||||
Returns a new animated actor composed of a mesh
|
||||
|
||||
The mesh can either be created using CreateMesh() or Loaded using LoadMesh()
|
||||
|
||||
#ref CreateMesh LoadMesh LoadMeshFromAN8
|
||||
<br>
|
||||
#ref CreateOctreeActor CreateCubeActor CreateSphereActor CreateWaterActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
@@ -4,3 +4,5 @@
|
||||
Returns a billboard actor
|
||||
|
||||
Billboard actors are flat textured planes that are always facing the camera.
|
||||
|
||||
#ref CreateAnimatedActor CreateOctreeActor CreateSphereActor CreateWaterActor CreateLightActor CreateCubeActor CreateTerrainActor
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
Returns an actor with a cube mesh of the specified size ( cube_size x cube_size x cube_size )
|
||||
|
||||
#ref CreateMeshActor CreateMeshOctreeActor CreateSphereActor CreateWaterPlaneActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
#ref CreateAnimatedActor CreateOctreeActor CreateSphereActor CreateWaterActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
#title CreateMeshActor [RCBasic Doc]
|
||||
#header function CreateMeshActor( mesh )
|
||||
#title CreateAnimatedActor [RCBasic Doc]
|
||||
#header function CreateAnimatedActor( mesh )
|
||||
|
||||
Returns a new actor composed of a mesh
|
||||
Returns a new animated actor composed of a mesh
|
||||
|
||||
The mesh can either be created using CreateMesh() or Loaded using LoadMesh()
|
||||
|
||||
#ref CreateMesh LoadMesh
|
||||
#ref CreateMesh LoadMesh LoadMeshFromAN8
|
||||
<br>
|
||||
#ref CreateMeshOctreeActor CreateCubeActor CreateSphereActor CreateWaterPlaneActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
#ref CreateOctreeActor CreateCubeActor CreateSphereActor CreateWaterPlaneActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
|
||||
8
doc/files/createoctreeactor.txt
Normal file
8
doc/files/createoctreeactor.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
#title CreateOctreeActor [RCBasic Doc]
|
||||
#header function CreateOctreeActor( mesh )
|
||||
|
||||
Returns a mesh actor optimized for large objects (such as levels)
|
||||
|
||||
#ref CreateMesh LoadMesh
|
||||
<br>
|
||||
#ref CreateAnimatedActor CreateCubeActor CreateSphereActor CreateWaterActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
Returns an actor composed of a sphere mesh
|
||||
|
||||
#ref CreateMeshActor CreateMeshOctreeActor CreateCubeActor CreateWaterPlaneActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
#ref CreateAnimatedActor CreateOctreeActor CreateBillboardActor CreateWaterActor CreateLightActor CreateCubeActor CreateTerrainActor
|
||||
|
||||
@@ -5,4 +5,4 @@ Returns terrain generated from a height map
|
||||
|
||||
Note: Height Maps can be any supported image format
|
||||
|
||||
#ref CreateMeshActor CreateMeshOctreeActor CreateCubeActor CreateSphereActor CreateWaterPlaneActor CreateLightActor CreateBillboardActor
|
||||
#ref CreateAnimatedActor CreateOctreeActor CreateSphereActor CreateWaterActor CreateLightActor CreateCubeActor CreateBillboardActor
|
||||
|
||||
@@ -2,3 +2,5 @@
|
||||
#header function CreateWaterActor( mesh, waveHeight, waveSpeed, waveLength )
|
||||
|
||||
Creates an actor with water properties set on a base mesh
|
||||
|
||||
#ref CreateAnimatedActor CreateOctreeActor CreateSphereActor CreateCubeActor CreateLightActor CreateBillboardActor CreateTerrainActor
|
||||
|
||||
4
doc/files/deleteactoranimation.txt
Normal file
4
doc/files/deleteactoranimation.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
#title DeleteActorAnimation [RCBasic Doc]
|
||||
#header sub DeleteActorAnimation(actor, animation)
|
||||
|
||||
Deletes an actor's animation
|
||||
6
doc/files/deletespriteanimation.txt
Normal file
6
doc/files/deletespriteanimation.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title DeleteSpriteAnimation [RCBasic Doc]
|
||||
#header Sub DeleteSpriteAnimation(sprite, animation)
|
||||
|
||||
Delete's a sprite's animation
|
||||
|
||||
#ref CreateSpriteAnimation
|
||||
6
doc/files/getactoranimationendframe.txt
Normal file
6
doc/files/getactoranimationendframe.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetActorAnimationEndFrame [RCBasic Doc]
|
||||
#header Function GetActorAnimationEndFrame(actor, animation)
|
||||
|
||||
Returns the last frame in an actor's animation
|
||||
|
||||
#ref SetActorAnimationFrames
|
||||
@@ -1,4 +1,6 @@
|
||||
#title GetActorAnimationSpeed [RCBasic Doc]
|
||||
#header function GetActorAnimationSpeed( actor )
|
||||
#header function GetActorAnimationSpeed( actor, animation )
|
||||
|
||||
Returns actors animation speed in frames per second
|
||||
Returns actor's animation speed in frames per second
|
||||
|
||||
#ref SetActorAnimationSpeed
|
||||
|
||||
6
doc/files/getactoranimationstartframe.txt
Normal file
6
doc/files/getactoranimationstartframe.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title GetActorAnimationStartFrame [RCBasic Doc]
|
||||
#header Function GetActorAnimationStartFrame(actor, animation)
|
||||
|
||||
Returns the first frame in an actor's animation
|
||||
|
||||
#ref SetActorAnimationFrames
|
||||
8
doc/files/getactorcurrentanimation.txt
Normal file
8
doc/files/getactorcurrentanimation.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
#title GetActorCurrentAnimation [RCBasic Doc]
|
||||
#header Function GetActorCurrentAnimation(actor)
|
||||
|
||||
Returns the current animation set on an actor
|
||||
|
||||
Note: Current animation will be 0 if the actor's frame was set with SetActorFrame()
|
||||
|
||||
#ref SetActorAnimation SetActorFrame
|
||||
7
doc/files/getactorframe.txt
Normal file
7
doc/files/getactorframe.txt
Normal file
@@ -0,0 +1,7 @@
|
||||
#title GetActorFrame [RCBasic Doc]
|
||||
#header function GetActorFrame(actor)
|
||||
|
||||
Returns the current frame number an actor is currently rendering
|
||||
|
||||
|
||||
#ref SetActorFrame GetActorAnimationFrame
|
||||
5
doc/files/numactoranimationloops.txt
Normal file
5
doc/files/numactoranimationloops.txt
Normal file
@@ -0,0 +1,5 @@
|
||||
#title NumActorAnimationLoops [RCBasic Doc]
|
||||
#header function NumActorAnimationLoops(actor)
|
||||
|
||||
Returns the total number of loops the actor is set to repeat the animation for
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
#title SetActorAnimation [RCBasic Doc]
|
||||
#header sub SetActorAnimation( actor, start_frame, end_frame)
|
||||
#header sub SetActorAnimation( actor, animation, num_loops)
|
||||
|
||||
Sets the start frame and end frame that an actor will loop through
|
||||
Sets the current animation for an actor to start playing
|
||||
|
||||
Note: Use LoopActorAnimation() to enable or disable animation looping
|
||||
Notes on num_loops
|
||||
#list ol
|
||||
#li <b>num_loops</b> is the number of times to loop the animation after its done playing. To play the animation once, set num_loops to 0.
|
||||
#li To loop an animation infinitely, set num_loops to -1
|
||||
#/list
|
||||
|
||||
#ref LoopActorAnimation SetActorFrame
|
||||
#ref CreateActorAnimation
|
||||
|
||||
6
doc/files/setactoranimationframes.txt
Normal file
6
doc/files/setactoranimationframes.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
#title SetActorAnimationFrames [RCBasic Doc]
|
||||
#header sub SetActorAnimationFrames(actor, animation, start_frame, end_frame)
|
||||
|
||||
Changes the frames that plays in an actor's animation
|
||||
|
||||
#ref CreateActorAnimation
|
||||
@@ -1,5 +1,5 @@
|
||||
#title SetActorAnimationSpeed [RCBasic Doc]
|
||||
#header sub SetActorAnimationSpeed( actor, speed )
|
||||
#header sub SetActorAnimationSpeed( actor, animation, speed )
|
||||
|
||||
Set the FPS of an actor animation
|
||||
|
||||
|
||||
@@ -2,3 +2,8 @@
|
||||
#header sub SetActorFrame( actor, frame )
|
||||
|
||||
Sets the current frame of an actor
|
||||
|
||||
Note: This function will set the actor's animation to 0 which is a default 1 frame animation that is created when the actor is created.
|
||||
|
||||
|
||||
#ref GetActorFrame
|
||||
|
||||
4
doc/files/spriteanimationisplaying.txt
Normal file
4
doc/files/spriteanimationisplaying.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
#title SpriteAnimationIsPlaying [RCBasic Doc]
|
||||
#header Function SpriteAnimationIsPlaying(sprite)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user