Differences
This shows you the differences between two versions of the page.
ff3:ff3us:doc:asm:fmt:npc [2016/08/15 01:40] m06 |
ff3:ff3us:doc:asm:fmt:npc [2019/02/12 11:42] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== NPC Data ====== | ||
- | |||
- | ===== Overview ===== | ||
- | |||
- | When a map is loaded, all NPCs defined for the specified map are loaded. | ||
- | |||
- | ===== Offsets ===== | ||
- | |||
- | ^ Description | ||
- | | Pointers (16-bit) | ||
- | | Nr of Pointers (bytes) | $01A0 ($0340) | ||
- | | Data Address | ||
- | | Block size | $09 | | ||
- | |||
- | The structure is a sequence of two-byte pointers. The index of the pointer is relative to the map number. | ||
- | |||
- | The actual offset of the appointed data is the pointer value plus the base offset. | ||
- | |||
- | The game system checks the actual pointer and the next pointer to determinate the amount of data to read. It can include multiple data blocks. | ||
- | |||
- | ===== Data ===== | ||
- | |||
- | ^ Offset | ||
- | | $00 | event address, low byte || | ||
- | | $01 | event address, middle byte || | ||
- | | $02 | $03 | event address, high bits | | ||
- | | ::: | $1C | palette | ||
- | | ::: | $20 | ?background scrolls | ||
- | | ::: | $C0 | bit identifier | ||
- | | $03 | $01 | bit identifier | ||
- | | ::: | $FE | byte identifier | ||
- | | $04 | $7F | X position | ||
- | | ::: | $80 | Show rider in vehicle | ||
- | | $05 | $3F | Y position | ||
- | | ::: | $C0 | Speed | | ||
- | | $06 | [[ff3: | ||
- | | $07 | $0F | movement type | | ||
- | | ::: | $30 | map layer | | ||
- | | ::: | $C0 | vehicle | ||
- | | $08 | $03 | start direction | ||
- | | ::: | $04 | don't change graphic | ||
- | | ::: | $18 | ?background layer | | ||
- | | ::: | $20 | ? | | ||
- | | ::: | $40 | ?mirror graphics | ||
- | | ::: | $80 | ? | | ||