Prev: 51463 Up: Map Next: 51500
51482: Nudge Object North South
Gives the player a push of one along x, towards the x position that is held in the speed along x of a door.
Input
IX Door record
IY Record of the legs of the player
Push one step towards the door along x.
NudgeObjectNorthSouth 51482 LD A,(IX+9) Fetch the x position of the place in front of the door.
51485 CP (IY+1) Compare it with the x position of the player.
51488 JR Z,NudgeObjectNorthSouth_Done Jump to NudgeObjectNorthSouth_Done if they are the same.
51490 LD A,1 Set the push to one.
51492 JR NC,NudgeObjectNorthSouth_Set Jump to NudgeObjectNorthSouth_Set if the place is further along than the player.
51494 NEG Make the push minus one.
NudgeObjectNorthSouth_Set 51496 LD (IY+14),A Set the push along x of the player.
This entry point is used by the routine at NudgeObjectEastWest.
NudgeObjectNorthSouth_Done 51499 RET Return.
Prev: 51463 Up: Map Next: 51500