Apt Data/Actions

From Burnout Wiki

Actions

Name Value Description
AptActionInvalid -1
AptActionEnd 0x00
AptActionNextFrame 0x04
AptActionPrevFrame 0x05
AptActionPlay 0x06
AptActionStop 0x07
AptActionToggleQuality 0x08
AptActionStopSounds 0x09
AptActionAdd 0x0A
AptActionSubtract 0x0B
AptActionMultiply 0x0C
AptActionDivide 0x0D
AptActionEquals 0x0E
AptActionLessThan 0x0F
AptActionAnd 0x10
AptActionOr 0x11
AptActionNot 0x12
AptActionStringEquals 0x13
AptActionStringLength 0x14
AptActionSubString 0x15
AptActionPop 0x17
AptActionToInteger 0x18
AptActionGetVariable 0x1C
AptActionSetVariable 0x1D
AptActionSetTarget2 0x20
AptActionStringAdd 0x21
AptActionGetProperty 0x22
AptActionSetProperty 0x23
AptActionCloneSprite 0x24
AptActionRemoveSprite 0x25
AptActionTrace 0x26
AptActionStartDragMovie 0x27
AptActionStopDragMovie 0x28
AptActionStringLessThan 0x29
AptActionThrow 0x2A
AptActionCastOp 0x2B
AptActionImplementsOp 0x2C
AptActionRandom 0x30
AptActionMBLength 0x31
AptActionCharToAscii 0x32
AptActionAsciiToChar 0x33
AptActionGetTimer 0x34
AptActionMBSubString 0x35
AptActionMBCharToAscii 0x36
AptActionMBAsciiToChar 0x37
AptActionDelete 0x3A
AptActionDelete2 0x3B
AptActionDefineLocal 0x3C
AptActionCallFunction 0x3D
AptActionReturn 0x3E
AptActionModulo 0x3F
AptActionNewObject 0x40
AptActionDefineLocal2 0x41
AptActionInitArray 0x42
AptActionInitObject 0x43
AptActionTypeOf 0x44
AptActionTargetPath 0x45
AptActionEnumerate 0x46
AptActionAdd2 0x47
AptActionLessThan2 0x48
AptActionEquals2 0x49
AptActionToNumber 0x4A
AptActionToString 0x4B
AptActionPushDuplicate 0x4C
AptActionStackSwap 0x4D
AptActionGetMember 0x4E
AptActionSetMember 0x4F
AptActionIncrement 0x50
AptActionDecrement 0x51
AptActionCallMethod 0x52
AptActionNewMethod 0x53
AptActionInstanceOf 0x54
AptActionEnumerate2 0x55
AptActionPushThis 0x56 Push string 'this'
AptActionPushGlobal 0x58 Push string '_global'
AptActionPush0 0x59 Pushes a byte of value 0 onto the stack
AptActionPush1 0x5A Pushes a byte of value 1 onto the stack
AptActionCallFuncAndPop 0x5B Call function and pop
AptActionCallFuncSetVar 0x5C Call function and set variable
Special function: ASSetPropFlags
AptActionCallMethodPop 0x5D Call method and pop.
  • Pops the method name (string) off the stack.
  • Pops the object this method is from.
  • Pops the argument count (integer).
  • Pops the arguments (any value). Number of pops is equal to the argument count.
  • Calls the method on the object, with the arguments supplied. There are some notable method names:
    • stop—Sets the object's play state to stopped.
    • gotoAndPlay—Gets the integer behind the object's property with the name given by the first argument. The object's current frame number is set to this value, and the play state is changed to playing.
    • gotoAndStop—Same as gotoAndPlay but the play state is changed to stopped.
AptActionCallMethodSetVar 0x5E Call method and set variable.
AptActionBitAnd 0x60
AptActionBitOr 0x61
AptActionBitXor 0x62
AptActionBitLShift 0x63
AptActionBitRShift 0x64
AptActionBitURShift 0x65
AptActionStrictEquals 0x66
AptActionGreater 0x67
AptActionExtends 0x69
AptActionPushThisVariable 0x70 Pushes the current scope (object) onto the stack.
AptActionPushGlobalVariable 0x71 Pushed the global object onto the stack.
AptActionPushZeroSetVar 0x72 Effectively AptActionPush0 followed by a SetVariable action.
  • Pop the variable name off the stack.
  • Set the variable with the given name in the current scope object to 0.
AptActionPushTrue 0x73 Pushes 'true' (Boolean) onto the stack.
AptActionPushFalse 0x74 Pushes 'false' (Boolean) onto the stack.
AptActionPushNULL 0x75 Pushes an object type with address 0 (NULL) onto the stack.
AptActionPushUndefined 0x76 Pushes undefined (is its own value type) onto the stack.
AptActionTraceStart 0x77
AptActionGotoFrame 0x81
AptActionGetUrl 0x83
AptActionStoreRegister 0x87 Store register.
See AptAction_StoreRegister.
AptActionDefineDictionary 0x88
AptActionWaitForFrame 0x8A
AptActionSetTarget 0x8B
AptActionGotoLabel 0x8C
AptActionDefineFunction2 0x8E
AptActionTry 0x8F
AptActionWith 0x94
AptActionPush 0x96
AptActionBranchAlways 0x99
AptActionGetUrl2 0x9A
AptActionDefineFunction 0x9B
AptActionBranchIfTrue 0x9D
AptActionCallFrame 0x9E
AptActionGotoFrame2 0x9F
AptActionPushString 0xA1 Pushes the given string to the stack.
See aligned structure AptAction_PushString.
AptActionPushStringDictByte 0xA2 Gets the constant with the given ID (see the Apt constant chunk) and pushes its value onto the stack..
This action has a 1-byte (unsigned integer) constant ID field.
AptActionPushStringDictWord 0xA3 Same as AptActionPushStringDictByte.
This action has a 2-byte (unsigned integer) constant ID field.
AptActionPushStringGetVar 0xA4 Gets the property with the given name from the current scope object, and pushes it onto the stack as an object. There are some special variable names:
  • _root—This represents the current scope object's root object (character).
  • MovieClip—Effectively the same as _root since all Apt files have a Movie as its root.
  • _parent—This represents the current scope object's parent object (character).
  • extern—This represents a special object that is responsible for extern variables/functions.

See aligned structure AptAction_PushString.

AptActionPushStringGetMember 0xA5
  • Pops an object off the stack.
  • Gets the property with the name given from this object.
    • There are some special member names: _root, MovieClip and _parent. See EA_GetStringVariable.
  • Pushes the property value onto the stack.

See aligned structure AptAction_PushString.

AptActionPushStringSetVar 0xA6
  • Pops the value to set off the stack.
  • Sets the current scope object's property with the given name to the popped value.

See aligned structure AptAction_PushString.

AptActionPushStringSetMember 0xA7
  • Pops the value to set off the stack.
  • Pops an object off the stack.
  • Sets the popped object's property with the given name to the popped value.

See aligned structure AptAction_PushString.

AptActionStringDictByteGetVar 0xAE Gets the string constant with the given ID (see the Apt constant chunk). This string is then used as the variable name in a process similar to EA_GetStringVariable.
This action has a 1-byte (unsigned integer) constant ID field.
AptActionStringDictByteGetMember 0xAF Gets the string constant with the given ID (see the Apt constant chunk). This string is then used as the member name in a process similar to EA_GetStringMember.
This action has a 1-byte (unsigned integer) constant ID field.
AptActionDictCallFuncPop 0xB0 This action has a 1-byte (unsigned integer) constant ID field.
  • Gets the string constant with the given ID (see the Apt constant chunk). This represents the function name.
  • Pops the argument count (integer) off the stack.
  • Pops the arguments off the stack. The number of pops is given by the argument count.
  • Gets the function with the name given from the current scope object.
  • Calls the function with the arguments.
AptActionDictCallFuncSetVar 0xB1 This action has a 1-byte (unsigned integer) constant ID field.
  • Gets the string constant with the given ID (see the Apt constant chunk). This represents the function name.
  • Gets the function with the name given from the current scope object.
  • Calls the function (no arguments). Some special functions:
    • stop—Sets the scope object's play state to stopped
    • setInterval—TODO
AptActionDictCallMethodPop 0xB2 This action has a 1-byte (unsigned integer) constant ID field.
  • Gets the string constant with the given ID (see the Apt constant chunk). This represents the method name.
  • Pops an object off the stack.
  • Pops the argument count (integer) off the stack.
  • Pops the arguments off the stack. The number of pops is given by the argument count.
  • Gets the method with the name given from the popped object.
  • Calls the function with the arguments. Some special functions are documented under AptActionCallMethodPop.
AptActionDictCallMethodSetVar 0xB3 This action has a 1-byte (unsigned integer) constant ID field.
  • Gets the string constant with the given ID (see the Apt constant chunk). This represents the method name.
  • Pops an object off the stack.
  • Gets the method with the name given from the popped object.
  • Calls the method (no arguments).
AptActionPushFloat 0xB4 Pushes the given float onto the stack.
This action has a 4-byte float field.
AptActionPushByte 0xB5 Pushes the given byte onto the stack.
This action has a 1-byte unsigned integer field.
AptActionPushWord 0xB6 Pushes the given word onto the stack.
This action has a 2-byte unsigned integer field.
AptActionPushDWord 0xB7 Pushes the given long onto the stack.
This action has a 4-byte unsigned integer field.
AptActionBranchIfFalse 0xB8 Does the same as action 0x9D (If), but checks if the condition is false rather than true.
See AptAction_BranchAddress. May be aligned.
AptActionPushRegister 0xB9 Push register.
AptActionBreakpoint 0xBA
LastAptAction 0xBB

Structures

AptAction_PushString

32-bit

Offset Length Type Name Description Comments
0x0 0x4 char* szStringToBePushed

64-bit

Offset Length Type Name Description Comments
0x0 0x8 char* szStringToBePushed

AptAction_BranchAddress

Offset Length Type Name Description Comments
0x0 0x4 int nTargetDelta

AptAction_StoreRegister

Offset Length Type Name Description Comments
0x0 0x4 int nRegister