Prev: AD07 Up: Map Next: AD57
AD46: Update Actor
Updates the display of an actor which has been moved. If the actor is in the same room as the player then it is drawn (see UpdateActorInRoom). If the actor is not in the room of the player but it was in the room last time (the room is held in Previous_Room) then it is removed from the screen.
Input
IX Actor record
UpdateActor AD46 LD A,($9703) Fetch the room of the player from 9703.
AD49 LD C,A Stash the room of the player in C.
AD4A CP (IX+$01) Jump to UpdateActorInRoom if the actor is in the same room as the player.
AD4D JR Z,UpdateActorInRoom
AD4F LD A,($96A2) Fetch the previous room of the actor from Previous_Room.
AD52 CP C Return if the actor was not in the room of the player.
AD53 RET NZ
AD54 JP RemoveEntity Jump to RemoveEntity to remove the actor from the screen.
Prev: AD07 Up: Map Next: AD57