![]() |
Routines |
| Prev: 47004 | Up: Map | Next: 47091 |
|
Used by the routine at Update_Berk_ReadControls.
Continue the down-control handler: bit tests, interact calls and put-down script launches.
|
||||
|
Skip ahead to Berk_ReadControls_DownPartT when the carry flag is clear.
|
||||
| Berk_ReadControls_DownBranch | 47009 | JR NC,Berk_ReadControls_DownPartT | Jump to Berk_ReadControls_DownPartT if the previous compare did not take carry. | |
|
This entry point is used by the routine at Update_Berk_ReadControls.
Test direction/state bit 1; otherwise continue the active script.
|
||||
| Berk_ReadControls_DownBitTest | 47011 | BIT 1,(IX+9) | Is bit 1 of the current entity's direction / state set?. | |
| 47015 | JP NZ,AdvanceScriptInstruction | If not, jump to AdvanceScriptInstruction. | ||
|
Face-left put-down when the bit test passed.
|
||||
| 47018 | SET 2,(IX+3) | Set bit 2 of the current entity's flags byte 3. | ||
| 47022 | LD HL,47747 | Point HL at BerkPutDownScript_WalkLeftFace. | ||
| 47025 | JP ScriptInstruction | Jump to ScriptInstruction to execute the script instruction at HL. | ||
|
This entry point is used by the routine at Update_Berk_ReadControls.
Shared down-branch: test direction bit 1 again, else run walk-right put-down.
|
||||
| Berk_ReadControls_DownPartT | 47028 | BIT 0,(IX+9) | Is bit 1 of the current entity's direction / state set?. | |
| 47032 | JP NZ,AdvanceScriptInstruction | If not, jump to AdvanceScriptInstruction. | ||
| 47035 | SET 2,(IX+3) | Set bit 2 of the current entity's flags byte 3. | ||
| 47039 | LD HL,47735 | Point HL at BerkPutDownScript_WalkRightFace. | ||
| 47042 | JP ScriptInstruction | Jump to ScriptInstruction to execute the script instruction at HL. | ||
|
This entry point is used by the routine at Update_Berk_ReadControls.
Choose interact vs continue from the referenced entity's y-extent.
|
||||
| Berk_ReadControls_DownPartU | 47045 | LD A,(IX+6) | Load A with the current entity's y-extent. | |
| 47048 | CP 27 | Is the y-extent equal to 27?. | ||
| 47050 | JR Z,Berk_ReadControls_DownPartV | If so, jump to Berk_ReadControls_DownPartV. | ||
| 47052 | CP 35 | Is the y-extent less than 35?. | ||
| 47054 | JP C,AdvanceScriptInstruction | If so, jump to AdvanceScriptInstruction. | ||
|
Interact, then either abort or copy the collided entity and run a put-down.
|
||||
| Berk_ReadControls_DownPartV | 47057 | CALL Berk_Interact_With_Entity | Call Berk_Interact_With_Entity to let Berk interact with an entity. | |
| 47060 | JR C,Berk_ReadControls_DownBitTest | If carry is set, jump to Berk_ReadControls_DownBitTest. | ||
| 47062 | JR NZ,Berk_ReadControls_DownPartT | If not zero, jump to Berk_ReadControls_DownPartT. | ||
| 47064 | LD BC,(29354) | Load BC with the last-collided entity pointer (Pointer_LastCollidedEntity). | ||
| 47068 | LD (29356),BC | Store BC in the current-entity pointer (Pointer_CurrentEntity). | ||
| 47072 | LD HL,47647 | Point HL at BerkPutDownScript_DownInteract. | ||
| 47075 | JP ScriptInstruction | Jump to ScriptInstruction to execute the script instruction at HL. | ||
|
This entry point is used by the routine at Update_Berk_ReadControls.
High y-extent interact path leading to the BerkPutDownScript_DownHighY put-down.
|
||||
| Berk_ReadControls_DownPartW | 47078 | CALL Berk_Interact_With_Entity | Call Berk_Interact_With_Entity to let Berk interact with an entity. | |
| 47081 | JR C,Berk_ReadControls_DownBitTest | If carry is set, jump to Berk_ReadControls_DownBitTest. | ||
| 47083 | JR NZ,Berk_ReadControls_DownPartT | If not zero, jump to Berk_ReadControls_DownPartT. | ||
| 47085 | LD HL,47965 | Point HL at BerkPutDownScript_DownHighY. | ||
| 47088 | JP ScriptInstruction | Jump to ScriptInstruction to execute the script instruction at HL. | ||
| Prev: 47004 | Up: Map | Next: 47091 |