![]() |
Routines |
| Prev: AB22 | Up: Map | Next: AB4A |
|
Writes the second operand into the turn counter selected by the first operand.
|
||||||||||
|
When the condition failed, skip this action.
|
||||||||||
| Action_SetTurnCounter | AB37 | JP NZ,RunScript_SkipAction_ThreeBytes | Jump to RunScript_SkipAction_ThreeBytes if the condition failed. | |||||||
|
The first operand selects a counter at TurnEventCounters; the second is the new value.
|
||||||||||
| AB3A | LD HL,$A0C9 | Point HL at the turn-event counters at TurnEventCounters. | ||||||||
| AB3D | LD E,(IX+$01) | Add the counter index from *IX+01. | ||||||||
| AB40 | LD D,$00 | |||||||||
| AB42 | ADD HL,DE | Point HL at that counter. | ||||||||
| AB43 | LD A,(IX+$02) | Fetch the new value from *IX+02 into A. | ||||||||
| AB46 | LD (HL),A | Store it in the selected counter. | ||||||||
| AB47 | JP RunScript_SkipAction_ThreeBytes | Jump to RunScript_SkipAction_ThreeBytes. | ||||||||
| Prev: AB22 | Up: Map | Next: AB4A |