EvilEngine/UIM

Format
A UI Motion asset begins with a 0x18-byte header which extends from xBaseAsset:

Following the header is a list of Commands (with a length of cmdCount). The format of each command is explained below.

Commands
There are 8 types of Commands defined:


 * 0 - Move
 * 1 - Scale
 * 2 - Rotate
 * 3 - Opacity
 * 4 - AbsoluteScale
 * 5 - Brightness
 * 6 - Color
 * 7 - UVScroll

Each command type has an 0x18-byte header:

Depending on the command type, the UI's corresponding property will be interpolated in between startTime and endTime to its new value (for example, the Color command will interpolate the UI's color from a starting red-green-blue value to an ending red-green-blue value). accelTime and decelTime can be used to "ease in" and "ease out" the interpolation so it appears to start and end smoothly.

Each command type is either absolute, relative, or relative to original.
 * Absolute means the property will be overwritten with a set value and changed over time to a new value.
 * Relative means the property will be changed from its existing value by a specified amount.
 * Relative to original means the property will be overwritten with its original value set in the asset and changed by a specified amount.

Absolute commands:
 * Opacity
 * AbsoluteScale
 * Brightness
 * Color

Relative commands:
 * Move
 * Rotate

Relative to original commands:
 * Scale
 * UVScroll

Move (Type 0)
Move the UI by a specified amount, relative to its last position.

Size = 0x20 bytes

Scale (Type 1)
Change the scale of the UI by a specified ratio, relative to its original scale set in the asset.

Size = 0x2C bytes

Rotate (Type 2)
Rotate the UI by a specified amount, relative to its last rotation.

Size = 0x24 bytes

Opacity (Type 3)
Change the opacity/alpha of the UI from a start to end value, overwriting its previous opacity.

Size = 0x1C bytes

AbsoluteScale (Type 4)
Change the scale of the UI from a start to an end ratio, overwriting its previous scale.

Size = 0x2C bytes

Brightness (Type 5)
Unknown. Might be related to bloom on Xbox

Size = 0x1C bytes

Color (Type 6)
Change the color of the UI from a start to an end value, overwriting its previous color.

Size = 0x20 bytes

UVScroll (Type 7)
Change the UI's UV offset by a specified amount, relative to its original UV set in the asset.

Size = 0x20 bytes