![]() |
Routines |
| Prev: E833 | Up: Map | Next: E894 |
|
Used by the routine at Handle_Sabreman_On_Rope.
Makes Sabreman fall off the rope when something hits him (a bubble, a creature or the falling stalactite). He tumbles, with the y velocity that is in B. His x velocity is the distance that the end of the rope moved (see Rope_End_Position) and the countdown in byte 0A is set to 14. The rope is made a type 17 object again, and Sabreman is drawn, at Restore_Type_17_Object.
|
||||||||||
| Knock_Sabreman_Off_Rope | E87B | LD A,($AA97) | Fetch the previous position of the end of the rope. | |||||||
| E87E | LD E,A | Store it in E. | ||||||||
| E87F | LD A,($AA95) | Fetch the position of the end of the rope. | ||||||||
| E882 | SUB E | Subtract the previous position. | ||||||||
| E883 | LD (IX+$06),A | Set the x velocity. | ||||||||
| E886 | LD (IX+$09),B | Set the y velocity. | ||||||||
| E889 | LD (IX+$00),$18 | Set the sprite id to 18 (tumbling). | ||||||||
| E88D | LD (IX+$0A),$14 | Set the countdown to 14. | ||||||||
| E891 | JP Restore_Type_17_Object | Jump to Restore_Type_17_Object. | ||||||||
| Prev: E833 | Up: Map | Next: E894 |