| Alien (BUGFIX 1.7) | Routines |
| Prev: 33395 | Up: Map | Next: 33479 |
|
The duct view's "move to:" rows: fill strip cells 2-5 from the room's four RoomAdjDucts slots (skipping no-exit entries), then overwrite each present exit with an anonymous direction arrow — strings 57-60 "North/East/South/West" — so the player sees where the crawlway leads but not what it leads to.
|
||||
| 33421 | LD A,(31242) | HL = RoomAdjDucts + room * 5 | ||
| 33424 | AND 63 | |||
| 33426 | LD L,A | |||
| 33427 | LD H,0 | |||
| 33429 | PUSH HL | |||
| 33430 | ADD HL,HL | room*5 = room*4 + room | ||
| 33431 | ADD HL,HL | |||
| 33432 | POP DE | |||
| 33433 | ADD HL,DE | |||
| 33434 | LD DE,29346 | RoomAdjDucts | ||
| 33437 | ADD HL,DE | |||
| 33438 | LD DE,29632 | DE -> strip cell 2 | ||
| 33441 | LD B,4 | four duct directions: | ||
| 33443 | LD C,(HL) | C = the destination that way; | ||
| 33444 | CP C | own room = no exit: leave the | ||
| 33445 | JR Z,33457 | cell empty (checked twice — A | ||
| 33447 | LD A,(31242) | holds a stale destination after | ||
| 33450 | AND 63 | a stored exit, so the reload | ||
| 33452 | CP C | makes the second test reliable) | ||
| 33453 | JR Z,33457 | |||
| 33455 | LD A,C | else cell = the destination room | ||
| 33456 | LD (DE),A | |||
| 33457 | INC DE | |||
| 33458 | INC HL | |||
| 33459 | DJNZ 33443 | |||
| 33461 | LD B,4 | second pass: disguise each | ||
| 33463 | LD HL,29632 | present exit as a direction | ||
| 33466 | LD C,57 | arrow (57 North ... 60 West) | ||
| 33468 | LD A,(HL) | |||
| 33469 | CP 255 | |||
| 33471 | JR Z,33474 | |||
| 33473 | LD (HL),C | |||
| 33474 | INC C | |||
| 33475 | INC HL | |||
| 33476 | DJNZ 33468 | |||
| 33478 | RET | |||
| Prev: 33395 | Up: Map | Next: 33479 |