![]() |
Routines |
| Prev: D153 | Up: Map | Next: D1BD |
|
Probe above with Test_EntityAbove. On a clear miss (carry set) jump to ScriptRoutine_VatIncXIfClearAbove_IncX to shift the vat right, then drop Y at ScriptRoutine_VatDecY. On a hit, if the distance in A is still under 32 continue into that same nudge; otherwise jump straight to ScriptRoutine_VatDecY to drop Y only.
|
||||||||
|
Probe above; carry set = miss (path clear).
|
||||||||
| ScriptRoutine_VatIncXIfClearAbove | D1AC | CALL Test_EntityAbove | Call Test_EntityAbove to test whether a solid entity sits above this vat. | |||||
| D1AF | JR C,ScriptRoutine_VatIncXIfClearAbove_IncX | Was the space above clear (carry set)? If so, jump to ScriptRoutine_VatIncXIfClearAbove_IncX to shift right. | ||||||
| D1B1 | CP $32 | On a hit: is the distance in A still under 32? If not, jump to ScriptRoutine_VatDecY to drop Y only (skip the nudge). | ||||||
| D1B3 | JR NC,ScriptRoutine_VatDecY | |||||||
|
Shift right (reached by jump on miss, or when A<32 on a hit), then drop Y.
|
||||||||
| ScriptRoutine_VatIncXIfClearAbove_IncX | D1B5 | INC (IX+$07) | Move the vat one character right. | |||||
| D1B8 | INC (IX+$08) | |||||||
| D1BB | JR ScriptRoutine_VatDecY | Jump to ScriptRoutine_VatDecY to decrease y / y-extent. | ||||||
| Prev: D153 | Up: Map | Next: D1BD |