Difference between revisions of "ANCS (File Format)"

From Retro Modding Wiki
Jump to: navigation, search
(woooooooah we're halfway theeeere)
Line 1: Line 1:
The '''ANCS format''' defines characters for animation in Metroid Prime 1 and 2. Starting in Metroid Prime 3, it was replaced by the [[CHAR (Metroid Prime 3)|CHAR]] format. The extension stands for '''AN'''imation '''C'''haracter '''S'''et.
+
The '''ANCS format''' defines character sets and animation sets in Metroid Prime 1 and 2. Starting in Metroid Prime 3, it was replaced by the [[CHAR (File Format)|CHAR]] and [[SAND (File Format)|SAND]] formats. The extension stands for '''AN'''imation '''C'''haracter '''S'''et.
  
 
__TOC__
 
__TOC__
  
== Root Structure ==
+
== Format ==
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Description
+
! Name
 
! Notes
 
! Notes
 
|-
 
|-
 
| u16
 
| u16
| Version
+
| '''Version'''
| Always 1
+
| Always 1.
|-
+
| [[#CharacterSet|CharacterSet]]
+
| Character Set
+
| Contains multiple [[#CharacterInfo|CharacterInfo]] Entries
+
 
|-
 
|-
| [[#AnimationSet|AnimationSet]]
+
| [[#Character Set|Character Set]]
| Animation Set
+
| '''Character Set'''
| Describes Meta Animations, Meta Transitions, Half Transitions, and Resource association
+
| Set of characters that share animation data.
 
|-
 
|-
 +
| [[#Animation Set|Animation Set]]
 +
| '''Animation Set'''
 +
| Set of animations used by the characters in the character set.
 
|}
 
|}
  
== CharacterSet ==
+
=== Character Set ===
  
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Element Count
+
! Count
! Description
+
! Name
 
! Notes
 
! Notes
 
|-
 
|-
 
| u16
 
| u16
 
| 1
 
| 1
| Version
+
| '''Version'''
| Always 1
+
| Always 1.
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| [[#CharacterInfoPair|CharacterInfoPair]] count
+
| '''Character Count'''
| Number of characters in this set.
+
| Count of characters in this set.
 
|-
 
|-
| [[#CharacterInfoPair|CharacterInfoPair]]
+
| [[#Character|Character]]
| character_info_count
+
| ''Character Count''
| Character Info Pairs
+
| '''Characters Array'''
|
+
| Array of characters.
 
|}
 
|}
  
=== CharacterInfoPair ===
+
==== Character ====
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Description
+
! Count
 +
! Name
 +
! Notes
 +
! V1
 +
! V2
 +
! V4
 +
! V5
 +
! V10
 
|-
 
|-
 
| u32
 
| u32
| Id
+
| 1
|-
+
| '''Character ID'''
| [[#CharacterInfo|CharacterInfo]]
+
| Typically begins at 0 and increments by 1 on each successive character in the set.
| Character Info
+
| {{check}}
|}
+
| {{check}}
 
+
| {{check}}
=== CharacterInfo ===
+
| {{check}}
{| class="wikitable"
+
| {{check}}
! Data Type
+
! Element Count
+
! Description
+
! Notes
+
 
|-
 
|-
 
| u16
 
| u16
 
| 1
 
| 1
| Info Type Count
+
| '''Version'''
| Informs the engine which info types are present within the CharacterSet
+
| This can vary between different files/characters. Usually 5 or 6 in MP1 and 10 in MP2.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| string
 
| string
 
| 1
 
| 1
| Character Name
+
| '''Name'''
| Human readable name, useful for editors, the engine does not use this internally.
+
| Name of the character. Not used by the game; was likely included for debugging purposes.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[CMDL_(Metroid_Prime)|CMDL]]
+
| Asset ID ([[CMDL (Metroid Prime)|CMDL]])
 
| 1
 
| 1
| Character Model
+
| '''Model ID'''
|
+
| ID of the model used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[CSKR_(File_Format)|CSKR]]
+
| Asset ID ([[CSKR_(File_Format)|CSKR]])
 
| 1
 
| 1
| Character Skin
+
| '''Skin ID'''
|
+
| ID of the skin used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[CINF_(File_Format)|CINF]]
+
| Asset ID ([[CINF_(File_Format)|CINF]])
 
| 1
 
| 1
| Character Rig
+
| '''Skeleton ID'''
|  
+
| ID of the skeleton used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| Animation Count
+
| '''Animation Name Count'''
| Animations in AnimationSet that specifically relate to this character, some characters make heavy use of this abstraction, Space Pirates being the biggest culprit.
+
| Count of animation names in the next array.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[#AnimationName|AnimationName]]
+
| [[#Animation Name|Animation Name]]
| animation_count
+
| ''Animation Name Count''
| Animation Names
+
| '''Animation Name Array'''
| Animations linked to this character by name and index.
+
| Array of names of animations used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[PASDatabase|PASDatabase]]
+
| [[PAS Database]]
 
| 1
 
| 1
| Parameterized Animation State Data
+
| '''PAS Database'''
 
| Not much is known about how this data is used.
 
| Not much is known about how this data is used.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[#ParticleResData|ParticleResData]]
+
| [[#Particle Resource Data|Particle Resource Data]]
 
| 1
 
| 1
| Particle systems used by this character
+
| '''Particle Resource Data'''
|
+
| List of particle assets being used by this character. This includes particles being used by attached effects as well as by [[EVNT (File Format)|animation events]].
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| colspan=2 {{unknown|'''Unknown'''}}
+
| {{unknown}}
 +
|  
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| {{unknown|'''Unknown'''}}
+
| {{unknown}}
| Not present when info_type_count <= 9
+
|  
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| {{unknown|'''Unknown'''}}
+
| '''Animation AABB Count'''
| Not present when info_type_count <= 9
+
| Count of animation bounding boxes.
|-
+
| {{nocheck}}
| u32
+
| {{check}}
| 1
+
| {{check}}
| Animation AABB count
+
| {{check}}
| Only present when info_type_count > 1
+
| {{check}}
 
|-
 
|-
| [[#AnimationAABB|AnimationAABB]]
+
| [[#Animation AABB|Animation AABB]]
| animation_aabb_count
+
| ''Animation AABB Count''
| Animation bounds
+
| '''Animation AABB Array'''
| Only present when info_type_count > 1
+
| Array of animation bounding boxes for this character.
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| Effect Count
+
| '''Effect Count'''
| Only present when info_type_count > 1
+
| Count of attached effects.
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| [[#Effect|Effect]]
 
| [[#Effect|Effect]]
| effect_count
+
| ''Effect Count''
| Effects used by this character, including which bones they're attached to
+
| '''Effect Array'''
| Only present when info_type_count > 1
+
| Effects attached to this character.
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[CMDL_(Metroid_Prime)|CMDL]]
+
| Asset ID ([[CMDL_(Metroid_Prime)|CMDL]])
 
| 1
 
| 1
| Overlay Model for status effects, such as ice when frozen
+
| '''Frozen Model'''
| Only present when info_type_count > 3
+
| Overlay model that appears when the character is frozen with the Ice/Dark Beam.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[CSKR_(File_Format)|CSKR]]
+
| Asset ID ([[CSKR_(File_Format)|CSKR]])
 
| 1
 
| 1
| Overlay Skin for status effects, such as ice when frozen
+
| '''Frozen Skin'''
| Only present when info_type_count > 3
+
| Skin for rigging the ''Frozen Model'' to the character's skeleton.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| Animation Index Count
+
| '''Animation Count'''
| The total number of animations used by this, only present when info_type_count > 4
+
| Count of animations used by this character.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
| animation_index_count
+
| ''Animation Count''
| Indices of each animation used by this character
+
| '''Animation ID Map'''
| Only present when info_type_count > 4
+
| Array of animation IDs. Indexing this array with the character-relative animation ID returns the animset-relative animation ID.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| u32
+
| Asset ID ([[CSPP (File Format)|CSPP]])
 
| 1
 
| 1
| {{unknown|'''Unknown'''}}
+
| '''Spatial Primitives ID'''
| Only present when info_type_count > 9
+
| ID of the spatial primitives used by this character.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|-
 
|-
 
| u8
 
| u8
 
| 1
 
| 1
| {{unknown|'''Unknown'''}}
+
| {{unknown}}
| Only present when info_type_count > 9
+
|  
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| Animation AABB Indexed Count
+
| '''Indexed Animation AABB Count'''
| Only present when info_type_count > 9
+
| Count of indexed animation bounding boxes.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|-
 
|-
| [[#AnimationAABB_Indexed|AnimationAABB]]
+
| [[#Indexed Animation AABB|Indexed Animation AABB]]
| animation_aabb_indexed_count
+
| ''Indexed Animation AABB Count''
| Animation bounds, referenced by index
+
| '''Indexed Animation AABB Array'''
| Only present when info_type_count > 9
+
| Unknown purpose.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|}
 
|}
  
====AnimationName====
+
===== Animation Name =====
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Element Count
+
! Name
! Description
+
 
! Notes
 
! Notes
 +
! V1
 +
! V10
 
|-
 
|-
 
| u32
 
| u32
| 1
+
| '''Animation ID'''
| Index
+
| Character-relative animation ID. Must be remapped via the ''Animation ID Map'' to access the corresponding animation in the animset.
| The index into AnimationSet's MetaAnimation table.
+
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| string
 
| string
| 1
 
 
| {{unknown|'''Unknown'''}}
 
| {{unknown|'''Unknown'''}}
| Not present when info_type_count >= 10
+
| Always empty.
 +
| {{check}}
 +
| {{nocheck}}
 
|-
 
|-
 
| string
 
| string
| 1
+
| '''Animation Name'''
| Animation Name
+
| The name of the animation.
| The name of the index ref'd Animation
+
| {{check}}
 +
| {{check}}
 
|}
 
|}
  
===ParticleResData===
+
===== Particle Resource Data =====
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Element Count
+
! Count
! Description
+
! Name
 
! Notes
 
! Notes
 +
! V5
 +
! V6
 +
! V10
 
|-
 
|-
 
| u32  
 
| u32  
 
| 1
 
| 1
| [[PART_(File_Format)|PART]] count
+
| '''Generic Particle Count'''
| How many particle systems are used by this character
+
| Count of generic particle systems.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[PART_(File_Format)|PART]]
+
| Asset ID ([[PART (File Format)|PART]])
| part_count
+
| ''Generic Particle Count''
| The particle systems used by this character
+
| '''Generic Particle List'''
 +
| List of generic particle systems used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| u32  
+
| u32
 
| 1
 
| 1
| [[SWHC_(File_Format)|SWHC]] count
+
| '''Swoosh Particle Count'''
| How many swooshes are used by this character
+
| Count of swoosh particle systems.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[SWHC_(File_Format)|SWHC]]
+
| Asset ID ([[SWHC (File Format)|SWHC]])
| swhc_count
+
| ''Swoosh Particle Count''
| The swooshes used by this character
+
| '''Swoosh Particle List'''
 +
| List of swoosh particle systems used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
 
| u32  
 
| u32  
 
| 1
 
| 1
| {{unknown|'''Unknown Count'''}}
+
| {{unknown}}
| How many unknown systems are used by this character
+
| Always 0.
|-
+
| {{nocheck}}
| UniqueID32
+
| {{check}}
| unknown_count
+
| {{check}}
| The unknown systems used by this character
+
 
|-
 
|-
 
| u32  
 
| u32  
 
| 1
 
| 1
| [[ELSC_(File_Format)|ELSC]] count
+
| '''Electric Particle Count'''
| How many electric systems are used by this character, only present if info_type_count > 5
+
| Count of electric particle systems.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 
|-
 
|-
| [[ELSC_(File_Format)|ELSC]]
+
| Asset ID ([[ELSC_(File_Format)|ELSC]])
| else_count
+
| ''Electric Particle Count''
| The electric systems used by this character
+
| '''Electric Particle List'''
| Only present if info_type_count > 5
+
| List of electric particle systems used by this character.
 +
| {{check}}
 +
| {{check}}
 +
| {{check}}
 +
|-
 +
| u32
 +
| 1
 +
| '''Spawn Particle Count'''
 +
| Count of spawn particle systems.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 +
|-
 +
| Asset ID ([[SPSC (File Format)|SPSC]])
 +
| ''Spawn Particle Count''
 +
| '''Spawn Particle List'''
 +
| List of spawn particle systems used by this character.
 +
| {{nocheck}}
 +
| {{nocheck}}
 +
| {{check}}
 
|}
 
|}
  
===AnimationAABB===
+
===== Animation AABB =====
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Description
+
! Name
 +
! Notes
 
|-
 
|-
 
| string
 
| string
| Name
+
| '''Animation Name'''
 +
|
 
|-
 
|-
| CAABox
+
| {{AABox}}
| Animation bounds
+
| '''Animation Bounding Box'''
 +
|
 
|}
 
|}
  
===Effect===
+
===== Indexed Animation AABB =====
 +
 
 +
Similar to [[#Animation AABB|Animation AABB]], but with animations referenced via ID instead of name.
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Element Count
+
! Name
! Description
+
! Notes
 +
|-
 +
| u32
 +
| '''Animation ID'''
 +
| Confirm this is character-relative?
 +
|-
 +
| {{AABox}}
 +
| '''Animation Bounding Box'''
 +
|
 +
|}
 +
 
 +
===== Effect =====
 +
 
 +
{| class="wikitable"
 +
! Type
 +
! Count
 +
! Name
 +
! Notes
 
|-
 
|-
 
| string
 
| string
 
| 1
 
| 1
| Name
+
| '''Effect Name'''
 +
| Name of the effect.
 
|-
 
|-
 
| u32
 
| u32
 
| 1
 
| 1
| Component Count
+
| '''Effect Component Count'''
 +
| Count of effect components
 
|-
 
|-
| [[#EffectComponent|EffectComponent]]
+
| [[#Effect Component|Effect Component]]
| component_count
+
| ''Effect Component Count''
| Effect Components
+
| '''Effect Components'''
 +
| Array of effect components used by this effect.
 
|}
 
|}
  
====EffectComponent====
+
====== Effect Component ======
 +
 
 
{| class="wikitable"
 
{| class="wikitable"
! Data Type
+
! Type
! Description
+
! Name
 +
! Notes
 
|-
 
|-
 
| string
 
| string
| Name
+
| '''Component Name'''
 +
| Name of this effect component.
 
|-
 
|-
| FourCC
+
| {{FourCC}}
| Type
+
| '''Particle Asset Type'''
 +
| Type of the particle used by this effect.
 
|-
 
|-
| UniqueID32
+
| Asset ID
| Resource as defined by Type
+
| '''Particle Asset ID'''
 +
| Particle resource used by this effect.
 
|-
 
|-
 
| string
 
| string
| Bone to attach the effect to
+
| '''Bone Name'''
 +
| Bone that the component is attached to.
 
|-
 
|-
 
| float
 
| float
| Scale
+
| '''Scale'''
 +
| Scale of the component.
 
|-
 
|-
 
| u32
 
| u32
| Parented Mode
+
| '''Parented Mode'''
 +
| Needs documentation
 
|-
 
|-
 
| u32
 
| u32
| Flags
+
| '''Flags'''
 +
| Needs documentation
 
|}
 
|}
 
===AnimationAABB Indexed===
 
The only difference between this and the previous [[#AnimationAABB|AnimationAABB]] is the fact that animations are referenced by index, rather than by name.
 
  
 
==AnimationSet==
 
==AnimationSet==

Revision as of 01:30, 3 March 2017

The ANCS format defines character sets and animation sets in Metroid Prime 1 and 2. Starting in Metroid Prime 3, it was replaced by the CHAR and SAND formats. The extension stands for ANimation Character Set.

Format

Type Name Notes
u16 Version Always 1.
Character Set Character Set Set of characters that share animation data.
Animation Set Animation Set Set of animations used by the characters in the character set.

Character Set

Type Count Name Notes
u16 1 Version Always 1.
u32 1 Character Count Count of characters in this set.
Character Character Count Characters Array Array of characters.

Character

Type Count Name Notes V1 V2 V4 V5 V10
u32 1 Character ID Typically begins at 0 and increments by 1 on each successive character in the set.
u16 1 Version This can vary between different files/characters. Usually 5 or 6 in MP1 and 10 in MP2.
string 1 Name Name of the character. Not used by the game; was likely included for debugging purposes.
Asset ID (CMDL) 1 Model ID ID of the model used by this character.
Asset ID (CSKR) 1 Skin ID ID of the skin used by this character.
Asset ID (CINF) 1 Skeleton ID ID of the skeleton used by this character.
u32 1 Animation Name Count Count of animation names in the next array.
Animation Name Animation Name Count Animation Name Array Array of names of animations used by this character.
PAS Database 1 PAS Database Not much is known about how this data is used.
Particle Resource Data 1 Particle Resource Data List of particle assets being used by this character. This includes particles being used by attached effects as well as by animation events.
u32 1 Unknown
u32 1 Unknown
u32 1 Animation AABB Count Count of animation bounding boxes.
Animation AABB Animation AABB Count Animation AABB Array Array of animation bounding boxes for this character.
u32 1 Effect Count Count of attached effects.
Effect Effect Count Effect Array Effects attached to this character.
Asset ID (CMDL) 1 Frozen Model Overlay model that appears when the character is frozen with the Ice/Dark Beam.
Asset ID (CSKR) 1 Frozen Skin Skin for rigging the Frozen Model to the character's skeleton.
u32 1 Animation Count Count of animations used by this character.
u32 Animation Count Animation ID Map Array of animation IDs. Indexing this array with the character-relative animation ID returns the animset-relative animation ID.
Asset ID (CSPP) 1 Spatial Primitives ID ID of the spatial primitives used by this character.
u8 1 Unknown
u32 1 Indexed Animation AABB Count Count of indexed animation bounding boxes.
Indexed Animation AABB Indexed Animation AABB Count Indexed Animation AABB Array Unknown purpose.
Animation Name
Type Name Notes V1 V10
u32 Animation ID Character-relative animation ID. Must be remapped via the Animation ID Map to access the corresponding animation in the animset.
string Unknown Always empty.
string Animation Name The name of the animation.
Particle Resource Data
Type Count Name Notes V5 V6 V10
u32 1 Generic Particle Count Count of generic particle systems.
Asset ID (PART) Generic Particle Count Generic Particle List List of generic particle systems used by this character.
u32 1 Swoosh Particle Count Count of swoosh particle systems.
Asset ID (SWHC) Swoosh Particle Count Swoosh Particle List List of swoosh particle systems used by this character.
u32 1 Unknown Always 0.
u32 1 Electric Particle Count Count of electric particle systems.
Asset ID (ELSC) Electric Particle Count Electric Particle List List of electric particle systems used by this character.
u32 1 Spawn Particle Count Count of spawn particle systems.
Asset ID (SPSC) Spawn Particle Count Spawn Particle List List of spawn particle systems used by this character.
Animation AABB
Type Name Notes
string Animation Name
AABox Animation Bounding Box
Indexed Animation AABB

Similar to Animation AABB, but with animations referenced via ID instead of name.

Type Name Notes
u32 Animation ID Confirm this is character-relative?
AABox Animation Bounding Box
Effect
Type Count Name Notes
string 1 Effect Name Name of the effect.
u32 1 Effect Component Count Count of effect components
Effect Component Effect Component Count Effect Components Array of effect components used by this effect.
Effect Component
Type Name Notes
string Component Name Name of this effect component.
FourCC Particle Asset Type Type of the particle used by this effect.
Asset ID Particle Asset ID Particle resource used by this effect.
string Bone Name Bone that the component is attached to.
float Scale Scale of the component.
u32 Parented Mode Needs documentation
u32 Flags Needs documentation

AnimationSet

Data Type Element Count Description Notes
u16 1 Info Count Enumeration of the presence of certain sections
u32 1 Animation Count How many animations there are in the set
Animation animation_count Animations that can be referenced by characters
u32 1 Transition Count How many transitions there are in the set
Transition transition_count Transitions that can be referenced by characters
MetaTransition 1 Default Transition
u32 1 Additive Animation Count How many additive animations there are
AdditiveAnimationPair additive_animation_count Additive animations that can be referenced in some fashion Reference method is currently unknown, presumably PASDatabase.
AdditiveAnimation 1 Default additive
u32 1 Half Transition Count How many half transitions there in the set, Only present if info_count > 2
HalfTransition half_transition_Count Half Transitions Only present if info_count > 2
u32 1 Animation Resource Count Only present if info_count > 3, and not present at all in MP2
AnimationResource animation_resource_count Animation Resources Only present if info_count > 3, and not present at all in MP2
u32 1 Event Count Only present in MP2
EVNT event_count Animation Events Only present in MP2

Animation

Data Type Description
string Name
MetaAnimation Animation configuration

MetaAnimation

MetaAnimations can be one of five types, and may contain children.

Data Type Description
EMetaAnimationType The Animation type
Play, Blend, PhaseBlend, Random or Sequence The animation description, including name, animation ID, and index used to connect character animations references to actual animations.

EMetaAnimationType

Name Value
Play 0
Blend 1
PhaseBlend 2
Random 3
Sequence 4

Play

Data Type Description Notes
ANIM Animation ID The asset ID for this particular animation
u32 Index The ID used by characters to reference this animation
string Name The animations name
float Unknown
u32 Unknown

Blend

Blend's structure is shared between Blend and PhaseBlend, with the only currently known difference being the animation type value.

Data Type Description Notes
MetaAnimation Animation A The animation to, presumably, blend from
MetaAnimation Animation B The animation to, presumably, blend to
float Unknown
bool Unknown

Random

Random may contain one or more children in an Animation -> Probability pair following this structure:

Data Type Element Count Description Notes
u32 1 Animation Count The number of child animations
AnimProbabilityPair animation_count The animations to select from The exact manner these are used is currently unknown
AnimProbabilityPair
Data Type Description Notes
MetaAnimation The animation use if the probability factor is met
u32 Probability How probability is used is not currently known

Sequence

Sequence is a fairly easy to understand type, it simply plays a list of animations in succession as each animation finishes

Data Type Element Count Description
u32 1 Animation Count
MetaAnimation animation_count The animations to play in a sequence

Transition

Data Type Description Notes
u32 Unknown
u32 Animation Index A The animation to transition from
u32 Animation Index B The animation to transition to
MetaTransition Transition configuration Describes how the transition is performed

MetaTransition

Meta Transitions can be one of four types, and may contain animations.

Data Type Description
EMetaTransitionType The type of transition
TransAnimation, TransTransition, TransPhaseTransition, TransNoTransition The transition configuration

EMetaTransitionType

Name Value
TransAnimation 0
TransTransition 1
TransPhaseTransition 2
TransNoTransition 3

TransAnimation

Data Type Description
MetaAnimation The animation to use while transitioning

TransTransition

Data Type Description
float Time
u32 Unknown
bool Unknown
bool Unknown
u32 Unknown

AdditiveAnimationPair

Data Type Description
u32 Animation Index
AdditiveAnimation Additive Animation fade-in, fade-out values

AdditiveAnimation

Describes how animations are additively blended together.

Data Type Description
float Fade In Duration
float Fade Out Duration

Half Transition

A half transition is very similar to a regular transition, but has less configuration information, any other differences are currently unknown

Data Type Description
u32 Animation Index
MetaTransition Transition configuration.

AnimationResource

Data Type Description
ANIM Animation Asset ID
EVNT Event Asset ID