| Alien (BUGFIX 1.7) | Routines |
| Prev: 37176 | Up: Map | Next: 37322 |
|
Draw message number A onto the bottom message line (screen row 23). The text is drawn over BLACK attributes, so it stays invisible until TickMessageQueue's cursor sweep reveals it column by column. Substitution codes: 254 = actor name (MsgParam1), 253 = target name (MsgParam2), 252 = room name (MsgParam1 as a room id).
Used by the routine at 37363.
|
||||
| 37221 | LD HL,20704 | draw at the message line (row 23) | ||
| 37224 | LD (31257),HL | |||
| 37227 | LD DE,33892 | find string number A: skip A | ||
| 37230 | AND A | 255-terminated strings | ||
| 37231 | JR Z,37242 | |||
| 37233 | LD B,A | |||
| 37234 | LD A,(DE) | |||
| 37235 | INC DE | |||
| 37236 | CP 255 | |||
| 37238 | JR NZ,37234 | |||
| 37240 | DJNZ 37234 | |||
| 37242 | LD A,(DE) | next message byte: | ||
| 37243 | CP 255 | end of string? | ||
| 37245 | JR Z,37310 | |||
| 37247 | CP 254 | the actor's name? | ||
| 37249 | JR Z,37271 | |||
| 37251 | CP 253 | the target's name? | ||
| 37253 | JR Z,37276 | |||
| 37255 | CP 252 | a room name? | ||
| 37257 | JR Z,37287 | |||
| 37259 | PUSH DE | plain character: blit it | ||
| 37260 | CALL 31369 | |||
| 37263 | POP DE | |||
| 37264 | INC DE | |||
| 37265 | LD HL,31257 | one column right | ||
| 37268 | INC (HL) | |||
| 37269 | JR 37242 | |||
| 37271 | LD A,(33712) | A = the actor's slot | ||
| 37274 | JR 37279 | |||
| 37276 | LD A,(33713) | A = the target's slot | ||
| 37279 | INC DE | |||
| 37280 | PUSH DE | print crew name A (CrewNameTable) | ||
| 37281 | CALL 31690 | |||
| 37284 | POP DE | |||
| 37285 | JR 37242 | |||
| 37287 | INC DE | |||
| 37288 | PUSH DE | |||
| 37289 | LD A,(33712) | A = the room id = its name's | ||
| 37292 | LD HL,(31257) | string index — a 10-character | ||
| 37295 | PUSH HL | strip via DrawSprite | ||
| 37296 | CALL 31634 | |||
| 37299 | POP HL | |||
| 37300 | LD DE,10 | advance 10 columns | ||
| 37303 | ADD HL,DE | |||
| 37304 | LD (31257),HL | |||
| 37307 | POP DE | |||
| 37308 | JR 37242 | |||
| 37310 | LD HL,(31257) | MsgDrawnCol = the end column, | ||
| 37313 | LD A,L | bit 7 set = "reveal sweep due" | ||
| 37314 | AND 31 | |||
| 37316 | OR 128 | |||
| 37318 | LD (33708),A | |||
| 37321 | RET | |||
| Prev: 37176 | Up: Map | Next: 37322 |