Skip to Content
The Alchemy Project

struct ACTOR_ARM_VIEW

ACTOR, field for field, as fdActorUpdateAll (actor_update_arm.c) reads it. More…

Declared in actor_update_arm.h.

Fields

NameDescription
const ACTOR_SCRIPT_WORDS *scriptNull when its slot is released.
Sint16scriptCursorIn words.
Uint16facing1/65536 turns.
FIXEDx16.16 fixed-point pixels.
FIXEDy16.16 fixed-point pixels.
FIXEDz16.16 fixed-point pixels.
FIXEDgroundHeight16.16 fixed-point pixels.
Sint32scaleXActor's scales and radius; not named here.
Sint32scaleY
Uint16radius
Uint8layerThe map layer whose ground height it follows.
Uint8priorityFlagsActor's; not named here.
FIXEDvelocityX16.16 fixed-point pixels per tick.
FIXEDvelocityY16.16 fixed-point pixels per tick.
FIXEDvelocityZ16.16 fixed-point pixels per tick.
FIXEDspeedLimit16.16 fixed-point pixels per tick.
FIXEDaccelerationAdded toward the target each tick, or taken off the speed when there is none, in 16.16 fixed-point pixels per tick.
FIXEDtargetX16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.
FIXEDtargetY16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.
FIXEDtargetZ16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.
union { FIXEDbounce, phase, vertical ; Sint32 phase; } verticalThe share of the falling speed kept on landing, 16.16 fixed point.
FIXEDgravityTaken off velocityY each tick above the ground, 16.16 fixed-point pixels per tick; also scales a floating actor's bob.
Sint32sceneWordActor's sceneWord, sprite and sprite kind; not named here.
void *sprite
Uint8spriteStorageKind
Uint8motionFlagsACTOR_MOTION_FLAG bits; zero is free flight in 3D.
Uint8arrivalAxisThe ARRIVAL_AXIS_* that decides arrival.
Uint8conditionResultThe actor script's last flag test; not named here.
Uint8snapToTargetNonzero lands it exactly on its target.
Uint8collisionFlagsBit 7: a solid actor refuses its move.
Uint8steeringFlagsACTOR_STEERING_FLAG bits.
Uint8pausedNonzero skips its script and motion, not its update function.
Uint8retainSpriteCacheActor's flag that keeps its
Uint8repeatCountsprite's VRAM, and the actor script's SC_LOOP count; not named here.
Sint16waitTicks left before its script runs again.
Uint8refusedTicks in a row a solid actor refused its move.
Uint8frozenNonzero skips steering, terrain, gravity and floating.
Uint8sceneCountActor's two bytes scene code uses, the actor script's parameter, the footprint side and the watched actor; not named here.
Uint8sceneByte
Sint16timer
Sint16userValue
struct ACTOR_ARM_VIEW *watchedActor
void (*update )(struct ACTOR *actor)Called each tick before its script.

Description

ACTOR, field for field, as fdActorUpdateAll (actor_update_arm.c) reads it. actor_update_arm.c is ARM code built with GCC 2.95.2, which cannot read ACTOR's anonymous unions, so it keeps this copy of the layout with the script as words and the bounce as a union.

struct ACTOR_ARM_VIEW

Referenced by fdActorUpdateAll().

Definition at line 26 of file actor_update_arm.h.

Fields in detail

script

const ACTOR_SCRIPT_WORDS *script

Null when its slot is released.

scriptCursor

Sint16 scriptCursor

In words.

facing

Uint16 facing

1/65536 turns.

x

FIXED x

16.16 fixed-point pixels.

y

FIXED y

16.16 fixed-point pixels.

z

FIXED z

16.16 fixed-point pixels.

groundHeight

FIXED groundHeight

16.16 fixed-point pixels.

scaleX

Sint32 scaleX

Actor's scales and radius; not named here.

scaleY

Sint32 scaleY

radius

Uint16 radius

layer

Uint8 layer

The map layer whose ground height it follows.

priorityFlags

Uint8 priorityFlags

Actor's; not named here.

velocityX

FIXED velocityX

16.16 fixed-point pixels per tick.

velocityY

FIXED velocityY

16.16 fixed-point pixels per tick.

velocityZ

FIXED velocityZ

16.16 fixed-point pixels per tick.

speedLimit

FIXED speedLimit

16.16 fixed-point pixels per tick.

acceleration

FIXED acceleration

Added toward the target each tick, or taken off the speed when there is none, in 16.16 fixed-point pixels per tick.

targetX

FIXED targetX

16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.

targetY

FIXED targetY

16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.

targetZ

FIXED targetZ

16.16 fixed-point pixels; ACTOR_NO_TARGET when unset.

bounce, phase, vertical

union { FIXED bounce; Sint32 phase; } vertical

The share of the falling speed kept on landing, 16.16 fixed point.

fixed point.

A floating actor's step along ActorScriptCycleTable, low six bits.

low six bits.

gravity

FIXED gravity

Taken off velocityY each tick above the ground, 16.16 fixed-point pixels per tick; also scales a floating actor's bob.

sceneWord

Sint32 sceneWord

Actor's sceneWord, sprite and sprite kind; not named here.

sprite

void *sprite

spriteStorageKind

Uint8 spriteStorageKind

motionFlags

Uint8 motionFlags

ACTOR_MOTION_FLAG bits; zero is free flight in 3D.

arrivalAxis

Uint8 arrivalAxis

The ARRIVAL_AXIS_* that decides arrival.

conditionResult

Uint8 conditionResult

The actor script's last flag test; not named here.

snapToTarget

Uint8 snapToTarget

Nonzero lands it exactly on its target.

collisionFlags

Uint8 collisionFlags

Bit 7: a solid actor refuses its move.

steeringFlags

Uint8 steeringFlags

ACTOR_STEERING_FLAG bits.

paused

Uint8 paused

Nonzero skips its script and motion, not its update function.

retainSpriteCache

Uint8 retainSpriteCache

Actor's flag that keeps its

repeatCount

Uint8 repeatCount

sprite's VRAM, and the actor script's SC_LOOP count; not named here.

wait

Sint16 wait

Ticks left before its script runs again.

refused

Uint8 refused

Ticks in a row a solid actor refused its move.

frozen

Uint8 frozen

Nonzero skips steering, terrain, gravity and floating.

sceneCount

Uint8 sceneCount

Actor's two bytes scene code uses, the actor script's parameter, the footprint side and the watched actor; not named here.

sceneByte

Uint8 sceneByte

timer

Sint16 timer

userValue

Sint16 userValue

watchedActor

struct ACTOR_ARM_VIEW *watchedActor

update

void (*update)(struct ACTOR *actor)

Called each tick before its script.