![]() |
Routines |
| Prev: 45738 | Up: Map | Next: 46144 |
|
Used by the routine at GameStart.
Copy room/x/x-extent from the camera-follow entity (StateData_Berk) into BerkRoomIndexCopy/BerkXCoordinateCopy/BerkXExtentCopy, then call Update_Berk_ReadControls with that IX.
|
||||
| Update_Berk_Controller | 46106 | LD IX,37019 | Point IX at the camera-follow entity (StateData_Berk). | |
| 46110 | LD A,(IX+4) | Load A with the current entity's room index. | ||
| 46113 | LD (29445),A | Set Berk's room-index copy (BerkRoomIndexCopy). | ||
| 46116 | LD A,(IX+7) | Load A with the current entity's x-coordinate. | ||
| 46119 | LD (29443),A | Set Berk's X-coordinate copy (BerkXCoordinateCopy). | ||
| 46122 | LD A,(IX+8) | Load A with the current entity's x-extent. | ||
| 46125 | LD (29444),A | Set Berk's X-extent copy (BerkXExtentCopy). | ||
| 46128 | LD HL,(29361) | Load HL with Berk's script position pointer (Pointer_BerkScriptPosition). | ||
| 46131 | LD (29391),HL | Store HL in the active script cursor (Pointer_ActiveScriptCursor). | ||
| 46134 | CALL Update_Berk_ReadControls | Call Update_Berk_ReadControls to read Berk's controls and choose a script. | ||
| 46137 | LD HL,(29391) | Load HL with the active script cursor (Pointer_ActiveScriptCursor). | ||
| 46140 | LD (29361),HL | Store HL in Berk's script position pointer (Pointer_BerkScriptPosition). | ||
| 46143 | RET | Return. | ||
| Prev: 45738 | Up: Map | Next: 46144 |