Animations file (X3)

From X-Wiki

Jump to: navigation, search
Although this file belongs to T files (X3) category, it is not true T file. It does not define any game objects.

Animations is one of files located in types directory in X3 Reunion. It holds informations about animated textures.

Contents

Structure

The file is using standard T files structure and BOD syntax.

Every record begins with two mandatory fields, the rest of the structure depends on value of the first field.

FieldDescription
Animation typeCan be:
  • TAT_ONESHOT
  • TAT_LOOP
  • TAT_TAGLOOP
  • TAT_PINGPONG
  • TAT_MOVIE
  • TAT_TAGCOLLECTION
  • TAT_TAGSINGLESTEP
  • TAT_TAGONESHOT_REINIT
FlagsCan be:
  • TADF_COORDS - adds 2 more fields to every frame where it's set - See Flags
additional valuesDepends on Animation type
Overal animation lengthSum of lengths of all frames within the animation

Animation type

TAT_ONESHOT

Simple animation which runs from start to end and terminates.

TAT_ONESHOT; NULL; 73; 89; 0; 500; // 1 fireball explosion

FieldDescription
Texture 1
Texture 2
Texture 3It's always 0. It's really 3rd texture?

TAT_LOOP

Animation which runs from start to end and then again from start.

TAT_LOOP; NULL; 633; 664; 0; 1000; // 58 caustic texture for water

FieldDescription
Texture 1
Texture 2
Texture 3

TAT_TAGLOOP

Animation which runs from start to end and then again from start. Allows explicit specification of width and height.

TAT_TAGLOOP; NULL; 121; 123; 4; NULL; 121; 600; NULL; 122; 200; NULL; 121; 200; NULL; 122; 200; 1200; // 8 position light 2

FieldDescription
Xwidth in pixels (0 = use full width)
Yheight in pixels (0 = use full height)
Frame countNumber of following frames
Frame
  • Flags
  • Texture name
  • Frame length

Example of an entry with TATF_COORDS flag:

TAT_TAGLOOP;NULL;0;0;11;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.00;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.066;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.132;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.198;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.264;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.33;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.396;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.462;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.528;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.594;
	TATF_COORDS;effects\weapons\fx_beam_diff;50;0.00;0.66;550; //85 - tug laser

Note the two additional fields in every frame (after the frame length).

TAT_PINGPONG

Animation which runs from start to end and then from end to start.

TAT_PINGPONG; NULL; 0; 0; 5; NULL; 314; 10000; NULL; 365; 20000; NULL; 314; 10000; NULL; 365; 30000; NULL; 314; 15000; 85000; // 37 station windows light map

FieldDescription
Xwidth in pixels (0 = use full width)
Yheight in pixels (0 = use full height)
Frame countNumber of following frames
Frame
  • Flags
  • Texture name
  • Frame length

Flags

TATF_COORDS

This flag adds two additional parameters to every frame where it's set: X and Y coordinates where the texture should be taken from the source file.

The coordinates are expressed in percents of the input image width and height.

TAT_TAGONESHOT; NULL; 0; 0; 16; 
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.00;0.00;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.25;0.00;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.50;0.00;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.75;0.00;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.00;0.25;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.25;0.25;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.50;0.25;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.75;0.25;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.00;0.50;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.25;0.50;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.50;0.50;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.75;0.50;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.00;0.75;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.25;0.75;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.50;0.75;
	TATF_COORDS;effects\explosions\exp_small_diff;50;0.75;0.75;800;// 71 small impact explosion

First entry: coordinates are [0, 0] which means that the texture will be copied from [0, 0] in the source image

Second entry: coordinates are [0.25, 0] which means X = 25% from input image width. The input image has dimensions 512 x 512 pixels which gives us 512 * 0.25 = 128 pixels. That means that the texture will be copied from coordinates [128, 0] from the input image.

Personal tools
sections