KEY file (short for Keyframe file) defines various animations of the mesh joint nodes of associated 3DO model. To edit KEY animations use Sith addon for Blender.
Required section. It defines basic animation properties:
-
FLAGS
Defines puppet track flags. Probably not used in the game. -
TYPE
Defines puppet high priority 3DO node types. By default all 3DO joint nodes have low priority assigned in the puppet file (.pup), if the node type is defined here then it will have high priority value assigned. Set this field to0xFFFF
if all nodes should have high priority assigned. -
FRAMES
The number of animation frames there are defined in this file aka length of this animation. -
FPS
Frames per second. How many frames should be played per second. -
JOINTS
The number of mesh joint nodes associated 3DO model has. Max 64.
This section defines frame markers aka frame types. The frame markers are used to produce special fx when the frame is played. For example, if the player walk animation contains frame marker 1 - LeftFoot
it will produce surface walk sound fx (depending on the type of surface player walk on) when that frame is played. The played marker is also send to the game object's COG script via callback message.
There can be ad max 16 markers. There are 35 known marker types you can see them below.
This section is not mandatory and can be omitted.
Example:
SECTION: MARKERS 2
7.000000 8 // 7 is frame number; 8 is marker type
18.000000 9
Marker Type | Name | Additional Info |
---|---|---|
0 | Default | |
1 | LeftFoot | |
2 | RightFoot | |
3 | Attack | |
4 | Swing | |
5 | SwingFinish | |
6 | SwimLeft | |
7 | Tread | water treading |
8 | RunLeftFoot | |
9 | RunRightFoot | |
10 | Died | |
11 | Jump | |
12 | JumpUp | |
13 | SwimRight | |
14 | Duck | |
15 | Climb | |
16 | Activate | Sends callback message to actor's COG. |
17 | Crawl | Maybe crouch |
18 | RunJumpLand | |
19 | ActivateRightArm | |
20 | ActivateRightArmRest | |
21 | PlaceRightArm | Sends callback message to actor's COG. |
22 | PlaceRightArmRest | Sends callback message to actor's COG. |
23 | ReachRightArm | Sends callback message to actor's COG. |
24 | ReachRightArmRest | Sends callback message to actor's COG. |
25 | Pickup | Sends callback message to actor's COG. |
26 | Drop | Sends callback message to actor's COG. |
27 | Move | |
28 | InventoryPull | Sends callback message to actor's COG. |
29 | InventoryPut | Sends callback message to actor's COG. |
30 | AttackFinish | Sends callback message to actor's COG. |
31 | TurnOff | Sends callback message to actor's COG. |
32 | Row | Raft |
33 | RowFinish | Raft |
34 | LeftHand | e.g.: Indy snd fx climbhandleft |
35 | RightHand | e.g.: Indy snd fx climbhandright |
This section defines animation frames for 3DO joint nodes. The section defined as list of 3DO node joints which have assigned list of animation frames, i.e.: list of position & orientation for the joint node at specific animation frame.
Structure:
NODES <N> // Number of joint nodes to be animated
// Followed by the joint node entries.
// Each node entry has defined:
NODE <3DO_HNODE_IDX> // The index number of joint node in the 3DO hierarchy list
MESH NAME <name> // 3DO mesh name
ENTRIES <N> // Number of animation frames in the list
// List of animation frames
# num: frame: flags: x: y: z: p: y: r:
# dx: dy: dz: dp: dy: dr:
0: 0 0x0003 0.00000000 0.00000000 0.00037000 0.00000000 0.00000000 -0.20175013
0.00000000 0.00000000 0.00061000 0.00000000 0.00000000 -0.30003664
1: 3 0x0003 0.00000000 0.00000000 0.00220000 0.00000000 0.00000000 -1.10186010
0.00000000 0.00000000 -0.00257333 0.00000000 0.00000000 -0.30001831
*Note: The `flags` represents what has changed since previous frame. i.e. 0x00 - Nothing changed, 0x01 - position changed, 0x02 - orientation changed.