Routines |
Prev: 36008 | Up: Map | Next: 36116 |
Used by the routine at 35735.
|
||||||||
36036 | BIT 1,(IX+9) | If Berk's facing-into-screen flag is reset... | ||||||
36040 | JP Z,36049 | ...then skip ahead to 36049 | ||||||
Berk's facing-into-screen flag is set
|
||||||||
36043 | LD HL,35073 | Point HL at script data for Berk turning (facing into screen to facing out of screen)... | ||||||
36046 | JP 48098 | ...and execute | ||||||
Berk's facing-into-screen flag is reset
|
||||||||
36049 | LD DE,0 | Clear pointer to complex state data for entity involved in last collision check... | ||||||
36052 | LD (34258),DE | ... | ||||||
36056 | CALL 54768 | Check entity at IX for collision with another entity at same depth whose interaction-(11,6) flag is set... | ||||||
36059 | JR C,36103 | ...and if no collision occurred, then skip ahead to 36103 | ||||||
Collision occurred
|
||||||||
36061 | CP 33 | If collision was not with an entity of class 33 (door)... | ||||||
36063 | JR NZ,36078 | ...then skip ahead to 36078 | ||||||
Collision with door
|
||||||||
36065 | CALL 36116 | If Berk is not horizontally aligned with door then move him closer and exit this routine | ||||||
Berk is now horizontally aligned with door
|
||||||||
36068 | LD (34256),IY | Store address of door's complex state data at 34256 | ||||||
36072 | LD HL,35045 | Point HL at script data for Berk interacting with a door in front of him... | ||||||
36075 | JP 48098 | ...and execute | ||||||
Collision with something other than door
|
||||||||
36078 | BIT 4,(IX+9) | If Berk's carrying-something flag is set... | ||||||
36082 | JP NZ,35786 | ...then jump to 35786 (terminate Berk's flight, or have him (turn to) face out of screen as appropriate) | ||||||
36085 | CP 22 | If collision was with an entity of class of 22 or greater (can't be picked up)... | ||||||
36087 | JP NC,35786 | ...then jump to 35786 (terminate Berk's flight, or have him (turn to) face out of screen as appropriate) | ||||||
At this point, Berk is not carrying anything, and the entity he is colliding with is one which can be picked up
|
||||||||
36090 | CALL 36116 | If Berk is not horizontally aligned with entity at IY then move him closer and exit this routine | ||||||
Berk is now horizontally aligned with entity pointed to by IY
|
||||||||
36093 | LD (34256),IY | Store address of entity's complex state data at 34256 | ||||||
36097 | LD HL,35187 | Point HL at script data for Berk picking up an entity on floor in front of him... | ||||||
36100 | JP 48098 | ...and execute | ||||||
No collision occurred
|
||||||||
36103 | BIT 4,(IX+9) | If Berk is not carrying anything... | ||||||
36107 | JP Z,35786 | ...then jump to 35786 (terminate Berk's flight, or have him (turn to) face out of screen as appropriate) | ||||||
Berk is carrying something
|
||||||||
36110 | LD HL,35205 | Point HL at script data for Berk putting an entity down on floor in front of him... | ||||||
36113 | JP 48098 | ...and execute |
Prev: 36008 | Up: Map | Next: 36116 |