1#ifndef ALCHEMY_SCRIPT_OBJECT_RUNTIME_H
2#define ALCHEMY_SCRIPT_OBJECT_RUNTIME_H
STATIC_ASSERT, a compile-time check that emits nothing.
#define STATIC_ASSERT(condition)
C89 permits repeated extern declarations of the same array.
#define offsetof(type, member)
A field object as its object script commands see it: the script and its place, position,...
s32 velocityY
16.16 fixed-point pixels per frame
u8 unk56[0x03]
The arrival axis, the last flag test and the snap flag; not named here.
s16 homeX
Its home, in pixels: where it was created or placed.
u8 animationKind
low four bits: 0 no sprite, 1 one, 2 up to four
u8 movementState
nonzero skips its script and motion (paused)
struct ScriptObjectRuntime * linkedObject
The object SC_FACE_LINK and SC_MOVE_LINK aim at.
u8 flags59
FieldActor.collisionFlags.
u8 unk23
FieldActor.priorityFlags; not named here.
s32 targetZ
16.16 fixed-point pixels; 0x80000000 when unset
s32 terrainHeight
16.16 fixed-point pixels
void * callback
Not named by TBS code through this struct: the refusal count, the frozen flag and two bytes scene cod...
s32 targetX
16.16 fixed-point pixels; 0x80000000 when unset
s32 x
16.16 fixed-point pixels
s32 speedLimit
16.16 fixed-point pixels per frame
u8 unk5c[0x02]
The flag that keeps its sprite's VRAM, and the object script's SC_LOOP count; not named here.
s32 y
16.16 fixed-point pixels
u8 terrainId
the map layer its ground height is read from
u8 unk44[0x0c]
bounce, gravity and a spare word; not named here
s32 velocityZ
16.16 fixed-point pixels per frame
s32 acceleration
16.16 fixed-point pixels per frame, per frame
s32 velocityX
16.16 fixed-point pixels per frame
const s32 * script
null when the object is free
s32 z
16.16 fixed-point pixels
u8 unk6c[0x04]
the update hook (FieldActor.update); not named here
u8 flags
FieldActor.motionFlags.
void * animation
its sprite, or its list of four, by animationKind
u16 scriptValue
The object's facing, 1/65536 turns: the heading SC_WANDER and SC_WANDER_HOME wander around,...
u8 unk18[0x0a]
the x and y scales and the radius; not named here
s32 targetY
16.16 fixed-point pixels; 0x80000000 when unset
u8 actionFlags
FieldActor.steeringFlags.
u16 turnedBack
The object script's wait, in frames (ScriptMotionObject.wait).
The integer types, TRUE, UNUSED and the fixed-address macros.