Classic Computer Magazine Archive A.N.A.L.O.G. ISSUE 69 / FEBRUARY 1989 / PAGE 10



TRIAL
BY FIRE


by Greg Knauss

The life of a fireman is tough. Tough like leather, tough like steel, tough like an elementary school teacher, tough like reading all these cliched similes. I am tough. And I am a fireman.
    I'd tried my hand at various professions other than fire fighting, sure, but none of them seemed to work out. Creative accounting, cat burglary, advising the President: I got caught-in at all of them. Eventually, I ended up being a fireman. I never intended to be a hero.
    Oh, I suppose it comes with the territory though. Firemen go through life and death situations every day, and most people never hear of it. Usually, if someone is pulled from a burning building, they'll never find out who did it just a faceless, nameless person in a funny-looking red hat and a tank of air. Not that it's fame that firemen are after-we fight fires to save lives and help people, not to get famous-but sometimes a fire has a little bizarre twist that gets it in the newspapers. And sometimes, you're involved.
    There was a fire like that a little while back in a nursery. Dozens, maybe hundreds, of babies trapped at the top story of a burning building. The stairs were gone, the flames were too big to get a ladder past, and the roof was way too small to land a helicopter on. We had one alternative left: the net. The net is what we use to catch people who have to jump from burning buildings. Unfortunately, some idiot had strung it way too tight. It was more a trampoline than a net. This was going to be a circus-in more ways than one. None of us wanted to use it, but we had nothing else.
    Me and a young kid-Tom somebodygrabbed the net and ran to the foot of the building. "Goo goo da-do!" he yelled. Later he insisted that that was baby-talk for "jump."
    The first baby who jumped tumbled down toward us, hit the net, and went right back up. It was amazing. We stood there gape-mouthed for a second before realizing that the baby had not bounced straight back up. He had drifted away from the building a little and was going to hit the ground unless we moved.
    We moved. Fast.
    Up he went again. And we moved again. After his third bounce, when we were getting worried whether he was ever going to come down, he landed right inside an ambulance that was parked nearby. Softly. As safe and as happy as he could be.
    Babies are supposed to have an innate fear of falling, but this kid seemed to love it. Someone had to hold him down because he tried to crawl back into the building to do it again.
    Another jumped, and we rushed back to the building.
    Up he went, again, and again, and again. It was going to be a long day.
    Like I said, firemen are tough.

Typing It In
    To make your copy of Trial by Fire, drop the Action! cartridge into the computer and threaten to beat up your little brother until he types in Listing 1. As a word of advice, the long lists of numbers are much more easily entered if you have a friend read them to you whilst you type.


The net is what we use to catch people
who have to jump from burning buildings.
Unfortunately, some idiot had
strung it way too tight.


    Now that you have entered the whole thing, make sure that your typing is correct with D: CHECK in Action!, and then save the file. Do not run it before storing it. Some of those annoyingly long lists of numbers are machine-language routines that will send your computer into the electronic equivalent of a coma if typed wrong.
    Now that there is a version safely saved, go to the monitor, compile and run the program.

screen shot

Playing the Game
    When the game first starts, you should see a building at the right of the screen with fire coming out of the second-story window, the back end of an ambulance at the right, and two firemen in the middle. A baby should be bouncing on their net for no very good reason.
    Press the Select key or move a joystick plugged into Port 1 in any direction to increase the level that you wish to start on. It automatically defaults to Level 1. To begin the game, push Start or the joystick button.
    When you start the game, push the joystick to the left. Soon a baby should jump out of the top story of the building. Wait until he bounces off the net that the firemen are holding, then let go of the joystick.
    The joystick is self-centering, so to return the firemen to the center position, just let go of the stick. To keep them positioned on either side of the screen you must hold the joystick in that direction. This system of movement takes a little getting used to, so be prepared to be frustrated for the first few games. If you are easily upset, have a relaxing record playing. Anything by Simon and Garfunkel will do.
    The baby will now bounce off the net again. Push the joystick to the right. One more bounce and the baby will safely land in the ambulance. (Yes, I realize the improbability of an ambulance with a sunroof, but if it didn't have one, there wouldn't be a game. So there.)
    Soon another baby will jump from the window.
    This continues until the number of babies you have saved is equal to the present level times three. When this happens the level is increased and you must then rescue a number of babies equal to that level times three.
    Difficulty also increases as the level goes up. Every even level the babies will not always bounce toward the ambulance. They have a fifty-fifty chance of just going straight up instead of to the right. This will catch you by surprise the first time it happens, especially if you play the game before reading these instructions. Crank Simon and Garfunkel up a notch.
    Also, at every third level, the number of babies that can be on the screen at one time is increased by one, up to four. So, on Level 10, there can be four babies on the screen at once and they won't always bounce toward the ambulance. This is generally known as chaos. And after Level 10, they start speeding up.
    Every time you successfully bounce a baby toward the ambulance, you get one point. For each baby that you get safely inside the ambulance, you get a bonus of the number of points equal to whatever level you are currently on. Level 1, one point; Level 6, six points.
    You can miss bouncing a baby three times before the game ends. After it's over, you will see the score you obtained, the high score, and the level you reached. To return to the title page, press the joystick button.
    If you start the next game by just pressing the joystick button or Start, the game will restart on the level that the previous game ended. If you fiddle with Select, a different level can be chosen.
    During play, the space bar will turn the pause feature on, and the joystick button will restart the game.

The End
    Another baby landed in the ambulance, and I sighed. I'd lost count long ago, but we must have saved hundreds during this fire. Hundreds of little, bouncing lives.
    We had to move-another had jumped and one was falling midway between the building and us. We ran and barely caught the one by the building. As he went up, we got under the other one. He bounced and we needed to get back under the first.
    We ran.
    I tripped.

    Greg Knauss is 20 years old and should probably be out looking for a real job like any other respectable young man. Instead, he has decided to write computer programs, listen to The Who and spend time with his girlfriend.


LISTING 1: ACTION
Blue indicates inverse video

; TRIAL BY FIRE
; BY GREG KNAUSS
; COPYRIGHT 1988 BY ANALOG COMPUTING
;
;      CHECKSUM DATA
;[DC ED BE OC 03 A5 3B BE
; 0C 57 BC E8 86 72 82 30
; A8 95 4A 7E 83 10 CB 94
; C6 BA 44 71 EA A2 10 4F
; 5F F8 73 68 2D 96 88 B4
; 42 58 CA 9A D4 65 98 ]

CARD I,DL,SC,CH,CH2,DRB,K,SCORE,
     HSCORE,SCR
BYTE S,J,PM,BABY,BABES,HIT,MISS,ADV,
     LVL,UD,BSAV,NXTL,KEY,BRN
CARD ARRAY X(5),Y(5),B(5),Q(5),UP(5)

PROC CHSET()

[0 0 0 0 0 0 0 0
0 0 1 85 2 2 2 5
0 0 0 0 0 0 8 0
0 85 86 85 162 170 160 170
0 64 128 80 0 128 128 128
0 1 2 5 0 2 2 0
0 85 149 85 138 170 170 170
0 0 64 85 128 128 128 80
5 5 5 1 0 1 1 3
64 84 85 85 0 85 85 255
0 0 111 104 0 64 64 192
0 0 255 0 0 0 0 0
0 0 249 41 0 1 1 3
5 21 85 84 1 85 85 255
80 80 64 0 64 64 64 192

1 5 5 21 21 64 80 252
85 85 69 1 1 0 0 0
64 64 64 80 80 30 80 252
1 1 5 5 21 20 20 252
85 85 65 0 0 0 0 0
64 80 80 84 84 20 20 252

255 255 255 255 255 255 255 2255
255 195 195 195 195 195 195 255
255 190 190 234 254 254 254 255
255 235 254 254 251 239 234 255
254 255 255 63 63 15 3 0
191 255 255 252 252 248 192 0
3 15 15 15 15 63 63 63
63 63 63 63 255 255 255 255
253 213 213 253 253 253 255 255
127 87 87 127 127 127 255 255
255 255 255 255 255 255 253 253
255 255 255 255 255 255 127 127]

PROC FIRE()
[255 255 255 255 255 253 245 247
0 0 0 1 1 68 64 0
117 85 119 215 213 85 85 85
255 215 211 215 215 199 215 255
85 85 87 87 93 85 87 127
85 119 95 95 127 255 255 255
255 255 247 245 245 213 215 87
223 253 125 117 245 85 85 85
81 81 69 84 84 80 64 0
16 0 1 17 16 17 85 85
245 197 213 215 215 215 87 95
85 85 85 85 65 85 85 85]

PROC FIRE2()
[255 255 255 255 253 253 245 213
0 0 8 0 8 4 16 0
93 125 117 65 93 93 85 85
255 211 215 199 215 199 199 255
87 87 93 85 87 119 95 127
117 119 127 255 255 255 255 255
255 255 255 253 247 213 215 85
221 125 245 245 213 85 85 93
85 84 68 16 16 64 0 0
0 1 1 64 68 68 69 85
245 213 213 213 211 211 87 95
85 85 85 85 85 85 85 85]
 

PROC BABIES()
[28 56 60 153 255 60 189 255
23 39 62 156 189 246 96 56
216 144 246 255 255 245 144 216
56 96 246 189 156 63 39 19
255 189 60 255 153 60 28 56
28 6 111 189 57 124 228 232
27 9 175 255 255 111 9 27
200 228 252 57 189 111 6 28
28 56 60 153 255 66 189 255
0 0 7 6 31 62 62 59
0 0 7 6 31 62 60 118
0 0 7 6 31 62 60 236
0 0 7 6 31 62 60 118]
 

PROC DLIST()
[112 112 70 0 0 7 130 16 68 0 0
4 4 4 4 4 4 4 4 4 4 4 4 132 4 4 4 132
4 65 DLIST]

PROC DLI()
[72 238 0 5 173 0 5 141 10
212 201 1 208 17 169 0 141 9 212 169
15 141 24 208 169 44 141 23 208 104
64 201 2 208 7 169 86 141 22 208 104
64 169 0 141 0 5 169 0 141 26 208
104 64]

PROC PLRVBI()
[162 3 189 244 6 240 89 56 221 240 6
240 83 141 254 6 106 141 255 6 142
253 6 24 169 0 109 253 6 24 109 252
6 133 204 133 206 189 246 6 133 203
173 254 6 133 205 189 248 6 170 232
46 255 6 144 16 168 177 203 145 205
169 0 145 203 136 202 208 244 76 87
6 160 0 177 203 145 205 169 0 145
203 200 202 208 244 174 253 6 173
254 6 157 240 6 189 236 6 240 48 133
203 24 138 141 253 6 109 235 6 133
204 24 173 253 6 109 252 6 133 206
189 240 6 133 205 189 248 6 170 160
0 177 203 145 205 200 202 208 248
174 253 6 169 0 157 236 6 282 48 3
76 2 6 76 98 228 0 0]

PROC YPOS()
[175 156 131 123 115 107 99 91 82 74
70 66 62 58 56 55 54 54 55 54 56 58
62 66 70 74 82 91 99 107 115 123 131
156 175 180]

PROC CLRS()
[44 246 72 56 76 15 146 8 146]
 

PROC BURN()
BRN=8-BRN POKE(1715,CH/256-BRN)
POKE(708,86+BRN/4) RETURN

PROC WAIT()
FOR K=1 TO 1000 DO OD RETURN

PROC SETUP()
GRAPHICS(0) POKE(82,0) POKE(752,1)
POKE(559,0)
CH=CPEEK(106)-8)*256
MOVEBLOCK(CH,CHSET,8*34)
MOVEBLOCK(CH+8*34,FIRE,13*8)
CH2=(PEEK(106)-16)*256
MOVEBLOCK(CH2,CHSET,8*34)
MOVEBLOCK(CH2+8*34,FIRE2,13*8)

DL=PEEKC(88) 5C=(PEEK(106)-40)*256
POKEC(DLIST+3,DL) POKEC(DLIST+9,SC)
POSITION(23,0)
PRINT("trial by fire") ZERO(5C,3072)
FOR I=0 TO 2 DO POKEC(88,5C+1024*I)
POKE(82,35) POSITION(35,15)
PRINT(";5?@5<5=>555555 9:")
POKE(82,0) POSITION(0,1)
PRINTE("555555") PRINTE("555555")
PRINTE("556655") PRINTE("55  55")
PRINTE("555555") PRINTE("555555")
PRINTE("556655") PRINTE("556655")
PRINTE("555555") PRINTE("55BHIDKC")
PRINTE("55LEMFJ") PRINTE("55ELFG")
PRINTE("555555") PRINTE("555555")
PRINTE("557855") PRINTE("555555")
PRINTE("555555") PRINTE("555555")
POKE(82,8+I*9) POSITION(8+I*9,16)
PRINTE("#$  %&'") PRINTE("()*++,-.")
PRINTE("/01 234") OD POKEC(88,DL)
MOVEBLOCK(1700,DLI,55)
POKE(1715,CH/256)
MOVEBLOCK(1536,PLRVBI,160)
PM=PEEK(106)-56 DRB=PM*256+1
ZERO(DRB+1024,1024) POKE(1788,PM+4)
POKE(53277,3) PCKE(54279,PM)
POKE(1771,PM) SETBLOCK(1784,4,8)
SETBLOCK(1772,4,1) FOR I=0 TO 3 DO
MOVEBLOCK(DRB+I*256,BABIES,104) OD
MOVEBLOCK(704,CLRS,9)
HSCORE=0 POKEC(560,DLIST)
POKEC(512,1700) POKE(1280,0)
POKE(54286,192) POKEC(548,PLRVBI)
POKE(559,62) RETURN

PROC MAIN()
SETUP() LVL=1 DO
POKE(1772,1) POSITION(2,1)
POKEC(DLIST+9,SC+1024)
POKE(53248,128) POKE(1780,180)
PRINT("     Copyright 1987 Magnum")
PRINT(" Opus     ") BRN=O
DO FOR I=0 TO 32 DO
J-PEEK(I+YPOS) POKE(1780,J+13)
WAIT() BURN()
KEY=NEEK(53279) IF KEY=5 OR
  STICK(0)<>15 THEN LVL==+l
IF LVL>9 THEN LVL=1 FI POSITION(7,1)
PRINT("         Level: ") PRINTB(LVL)
PRINT("         ") FI
J=STRIG(0) POKE(77,0)
IF KEY=6 OR J=0 THEN EXIT FI OD
UNTIL KEY=6 OR J=0 OD POKE(53248,0)
SCORE=0 SCR=0 BSAV=0 MISS=0 ADV=0
BRN=0 NXTL=3*LVL BABES=LUL/3+1
UD=1-LVL MOD 2 POSITION(7,1)
PRINT("       Get ready...       ")
FOR I=1 TO 100 DO BURN() WAIT() OD
POSITION(2,1) PRINT("Misses: 0")
PRINT("    Scope: 0      Level: ")
PRINTB(LVL)

DO
FOR I=1 TO 4 DO X(I)=0 Y(I)=0 B(I)=0
Q(I)=0 UP(I)=l OD HIT=0
DO POKE(77,0) 5NDRST() S=STICK(0)
IF S=11 THEN J=0 ELSSEIF S=7 THEN J=2
  ELSE J=1 FI
POKEC(DLIST+9,SC+J*1024) BURN()
IF ADV=1 AND BSAV MOD NXTL=0 THEN
  LVL==+1 POSITION(36,1) PRINTB(LVL)
  NXTL=LVL*3 BSAV=0 ADV=2 UD=0 FI
IF LVL MOD 2=0 AND ADV=2 THEN UD=1 FI
IF LVL MOD 3=0 AND ADV=2 THEN
  BABES==+1 ADV=0 FI
IF LVL MOD 2=0 THEN ADV=0 FI
IF LVL>10 THEN UD=1-LVL MOD 2 BABES=4
  FI
IF SCR>SCORE THEN SCORE=SCR
  POSITION(22,1) PRINTC(SCORE) FI
FOR BABY=1 TO BABES DO
POKE(1772+BABY-1,Q(BABY)/4*8+1)
POKE(1780+BABY-1,Y(BABY)+8)
POKE(53248+BABY-1,X(BABY))
IF B(BABY)=1 THEN X(BABY)==+UP(BABY)
  Q(BABY)==+1
  Y(BABY)=PEEK(YPOS+Q(BABY))
IF Y(BABY)>175 AND X(BABY)=92 AND
  J<>0 THEN HIT=1 FI
IF Y(BABY)>175 AND X(BABY)=127 AND
  J<>1 THEN HIT=1 FI
IF Y(BABY)>175 AND X(BABY)=162 AND
  J<>2 THEN HIT=1 FI
IF Y(BABY)>175 AND HIT=0 THEN
  Q(BABY)=0 SOUND(0,200,18,10)
  UP(BABY)=1 IF UD=1 THEN
  UP(BABY)=RAND(2) FI SCR==+UP(BABY)
  FI
IF X(BABY)>195 THEN X(BABY)=0
  Y(BABY)=0 Q(BABY)=0 B(BABY)=0
  BSAV==+1 ADV=1 SCR==+LVL FI FI
IF RAND(25)<l AND B(BABY)=0 AND
  (Q(1)<5 OR Q(1)>15) AND
  (Q(2)<5 OR Q(2)>15) THEN IF
  (Q(3)<5 OR Q(3)>15) AND
  (Q(4)<5 OR Q(4)>15) THEN X(BABY)=67
  Q(BABY)=10 B(BABY)=1 S=RAND(4)
  K=PEEK(CLRS+5) POKE(703+BABY,K) FI
  FI
  OD
IF LVL<11 THEN WAIT() ELSE
  FOR K=1 TO 2000-LVL*100 DO OD F1
IF PEEK(764)=33 THEN DO POKE(77,0)
  SNDRST() UNTIL STRIG(0)=0 OD
  POKE(764,255) F1
UNTIL HIT<>0 OD

FOR BABY=1 TO BABES DO
IF Y(BABY)<176 THEN
  POKE(53248+BABY-1,0) FI
IF Y(BABY)>175 THEN
  POKE(1780+BABY-1,215) J=BABY
  FOR I=1 TO 1000 DO OD FI OD
MISS==+1 POSITION(10,1) PRINTB(MISS)
SOUND(0,200,8,12) FOR I=1 TO 60 DO
BURN() WAIT() IF I=3 THEN SNDRST() FI
OD BABY=9 FOR I=X(J) TO 255 DO BURN()
POKE(1772+J-1 BABY*8+1) BABY==+1
IF BABY=12 TUN BABY=9 FI
POKE (53248+J-1,I) WAIT()
POKE(764,255) OD IF MISS=3 THEN EXIT
  FI
OD

IF SCORE>HSCORE THEN HSCORE=SCORE FI

POSITION(1,1) PRINT("            ")
PRINT("                          ")
POSITION(1,1) PRINT("Score: ")
PRINTC(SCORE) POSITION(13,1)
PRINT("High Score: ") PRINTC(HSCORE)
POSITION(30,1) PRINT("Level: ")
PRINTB(LVL) DO BURN() WAIT() UNTIL
STRIG(0)=0 OD FOR K=1 TO 10000 DO OD
POSITION(l,1) PRINT("            ")
PRINT("                          ")
OD