- Opcode: 0x042
- Short name: FMOVE
- Long name: Facing? Move
Argument
none
Stack
X
Y
Z
Movement angle (usually 0)
FMOVE
Description
Moves this entity. Unlike the other move functions, this will not cause the entity’s walk animation to play, but will make it face in the direction of movement. The top stack value is popped into the movement-angle field (move_angle_current, entity+538); the next three are the destination X, Y, Z (move_pos_x/y/z, entity+436/+440/+444, shifted left by 12). Sets motion_state (entity+572) to 1 and pauses until arrival (motion_substate == 2), then restores the idle animation and returns 2.
PC handler: SCRIPT_FMOVE.
Function addresses
| Function | Address | Description |
|---|---|---|
SCRIPT_FMOVE | 0x523C20 | Field script opcode handler (verified IDA function) |