Prev: 58518 Up: Map Next: 58651
58570: Move Eagle To Next Room
Used by the routine at Limit_Eagle_Vertical_Movement.
Moves the eagle and Sabreman into the next room. There is an entry point for each direction, and the first one (Move_Eagle_To_Next_Room) is for the room above. The eagle and Sabreman are put at the opposite edge of the new room, and the room is drawn.
Input
IX Object record of the eagle
Move_Eagle_To_Next_Room 58570 DEC (IX+4) Move the eagle to the room above.
58573 LD A,168 Set the y position of the eagle to 168.
58575 LD (IX+3),A
58578 LD A,184 Set the y position of Sabreman to 184.
58580 LD (36643),A
Move_Eagle_To_Next_Room_Set_Room_Y 58583 LD A,(IX+4) Fetch the room y of the eagle.
58586 LD (36638),A Set the room y of Sabreman.
Move_Eagle_To_Next_Room_Draw 58589 LD (IX+15),1 Set the redraw flags of the eagle to 1 so that it is drawn without being erased first.
58593 CALL Update_Object_Sprite Draw the eagle.
58596 JP Draw_Room Jump to Draw_Room.
This entry point is used by the routine at Limit_Eagle_Vertical_Movement.
Move_Eagle_To_Room_Below 58599 INC (IX+4) Move the eagle to the room below.
58602 LD A,40 Set the y position of the eagle to 40.
58604 LD (IX+3),A
58607 LD A,56 Set the y position of Sabreman to 56.
58609 LD (36643),A
58612 JR Move_Eagle_To_Next_Room_Set_Room_Y Jump to Move_Eagle_To_Next_Room_Set_Room_Y.
This entry point is used by the routine at Limit_Eagle_Sideways_Movement.
Move_Eagle_To_Room_On_Left 58614 DEC (IX+2) Move the eagle to the room on the left.
58617 LD A,231 Set the x position of the eagle and of Sabreman to 231.
58619 LD (IX+1),A
58622 LD (36642),A
Move_Eagle_To_Next_Room_Set_Room_X 58625 LD A,(IX+2) Fetch the room x of the eagle.
58628 LD (36636),A Set the room x of Sabreman.
58631 LD A,17 Set the contact flags of Sabreman to 17.
58633 LD (36645),A
58636 JR Move_Eagle_To_Next_Room_Draw Jump to Move_Eagle_To_Next_Room_Draw.
This entry point is used by the routine at Limit_Eagle_Sideways_Movement.
Move_Eagle_To_Room_On_Right 58638 INC (IX+2) Move the eagle to the room on the right.
58641 LD A,8 Set the x position of the eagle and of Sabreman to 8.
58643 LD (IX+1),A
58646 LD (36642),A
58649 JR Move_Eagle_To_Next_Room_Set_Room_X Jump to Move_Eagle_To_Next_Room_Set_Room_X.
Prev: 58518 Up: Map Next: 58651