0x239 animate-gfx-srcrect-target
Opcode 0x239 (569), draw. Investigated by OME, with high confidence (from investigation).
(handle)(delay_ms)(duration_ms)(frame_count)(column_count)(flags) — finite one-shot row-major source-rectangle cell channel, the fifth one-shot channel (op 0x21c waits for it). Worker gfx_worker_set_srcrect_cell @0x47ed90 requires the visible bit, sets object flag bit 1, zeroes the shared start obj+0x34, and stores delay +0x48, duration +0x5c, frame count +0x238, columns +0x23c and flags +0x234. After the delay, cell = elapsed*frame_count/duration (row = cell/columns, column = cell%columns) offsets the source rect by whole cells. Flag bit 0 commits the last cell at the end, otherwise the source rect collapses to empty; flag bit 1 draws the base cell during the delay, otherwise nothing is drawn. BTL's sword-clash intro uses (0, 1000, 28, 7, 0).
Operands
| # | Role | Types seen | Access |
|---|---|---|---|
| 1 | — | imm, g-int, l-int | read |
| 2 | — | imm, l-ptr | read |
| 3 | — | imm, l-int, l-ptr | read |
| 4 | — | imm, l-ptr | read |
| 5 | — | imm, l-ptr | read |
| 6 | — | imm | read |
In the port
OME’s port implements it. It never waits: a wait parks the engine until input, a sleep, a transition, a dialog or a movie ends. What it can do with control besides waiting:
falls: it returns to the next instruction
OME derives these facts from the port’s handler (its tools/opcode_flow.py), and they over-approximate: a fact some path can reach is given.
By build
Whether each build’s scripts use it, as OME’s survey of the game’s scripts saw them, and how many evidence items name the build.
| Build | Game | Used by its scripts | Evidence |
|---|---|---|---|
4.24J (SYS4422) | Himegari Dungeon Meister | yes | 1 |
4.33G (SYS4433) | Kamidori Alchemy Meister | yes | — |
4.38D (SYS4438) | Soukoku no Arterial | yes | — |
Evidence
- native-re on SYS4422, high confidence; Himegari AGE.EXE Ghidra /v2 and decoded script corpus (
vm-map/opcodes.toml opcode 0x239): Native /v2 worker and gfx_object_apply_transform_channels@0x472f00 disassembly 0x473cf9-0x473ec6 (2026-11-04): duration +0x5c > 0 keeps the channel live; before start+delay the working rect collapses unless +0x234 bit 1; at or after start+delay+duration (or forced completion) delay/duration are zeroed and +0x234 bit 0 selects last-cell commit versus collapse, written back to obj+0x8..+0x14. The surviving-channel count clears flag bit 1, 0x2d0 bit 0 and the start. BTL@0x539 plays the 28-cell sword clash before mark-frame-yield.