Skip to content

Latest commit

 

History

History
105 lines (81 loc) · 2.91 KB

avatar.md

File metadata and controls

105 lines (81 loc) · 2.91 KB

Avatar File

There are currently 3 avatars:

  • Brian
  • Chris
  • Pablo

Avatar files are 3D model files with the rn8 file extension. Model units are in centimeters.

Root Structure

Type ID Description
Int32 vertex_count Divide by 7
vertex_struct[] vertices
Int32 texture_count Add 6
C# String[] textures
Boolean is_ushort_index_buffer True if the indices are stored as ushorts
Int32 num_index_buffer
UShort[] ushort_index_buffer1
Int32[] index_buffer2
Int32 num_unknown_structs Subtract 9
unknown_struct[] unknown_structs
Int32 num_skeleton_hierarchy
Int32[] skeleton_hierarchy
Int32 num_bone_indices
bone_index_struct[] bone_indices
Int32 num_bind_poses
Matrix4x4[] bind_poses
Int32 num_inverse_bind_poses
Matrix4x4[] inverse_bind_poses
Int32 num_animations Seems to always be 16
animation_clip[] animations
  • 1: Only if the index buffer is ushort
  • 2: Only if the index buffer is not ushort

Types

vertex_struct

Type ID Description
Float reserved1
Float position_x Multiply by 63.7f
Float normal_y Divide by -1.732f
Float position_z Divide by 16f
Float tex_coord_x Divide by 4.8f
Float normal_x Divide by 10.962f
Float reserved2
Float normal_z Divide by 11.432f
Float tex_coord_y Divide by 9.6f
Float position_y Multiply by 6f
UInt8 blend_index_w
Float blend_weight_z
UInt8 blend_index_x
Float blend_weight_y
UInt8 blend_index_y
Float blend_weight_w
UInt8 blend_idex_z
Float blend_weight_x

unknown_struct

Type ID Description
Int32 reserved This field is unused
Int32 texture_index1
Int32 num_index_buffer
Int32 start_index_location
Int32 base_vertex_location
  • 1: _mrao is appended to the texture name

bone_index_struct

Type ID Description
C# String key
Int32 bone_index

animation_clip

Type ID Description
C# String clip_name
Double duration Duration in ms
Int32 num_keyframes
animation_keyframe[] keyframes

animation_keyframe

Type ID Description
Int32 bone_index
Double time
Matrix4x4 transform