IUGC500@INDYVAX.IUPUI.EDU (David Holland IUGC500@INDYVAX) (04/19/91)
Hallo ppl I remembered someone mentioning a hp-28 version of tetris well, I found a copy of it out on a ftp site tonight. I've not typed it in yet, so I can't say how well it plays, but its probably not as fast as the more recent versions of tetris for the 48 I would guess. but I was wondering if there's enough interest in it for me to post the thing to the networks. well? Oh, yah, I'm not on the hp-28 mailing list, so someone will have to let me know, but otherwise, I'll leave it laying about my account for a while and see what turns up. (oh, yah, NO I didn't write this version, I just found a copy of it on a ftp site I can't remember the name of off hand. The real author is a David Still ie. DESTILL@MTUS5.CTS.MTU.EDU) bye all David Holland IUGC500@INDYVAX.IUPUI.EDU
IUGC500@INDYVAX.IUPUI.EDU (David Holland IUGC500@INDYVAX) (04/22/91)
Hello ppl! Well, I decided it would be easier if I just posted the program to both groups. Below is an exact copy of the program as I found it. I finally figured out what the FTP site was. Its GMUVAX2.GMU.EDU (129.174.1.8) for those people who wish to go get it themselves. There's also quite a bit of other 28 stuff there (Its one of the standard program archives.. I think.) Its (curiously) in the directory: new intead of the right hp28 directory, and its also called: blokdrop.hp28 Oh well, here it is.. David Holland IUGC500@INDYVAX (BITNET) IUGC500@INDYVAX.IUPUI.EDU (INTERNET) [ORIGINAL MESSAGE FOLLOWS] ------------------------------------------------------------------------------- One of the great liabilities of the HP-28 is its inability to play TETRIS. Okay, so that's not really much of a liability, but I got tired of watching all of my friends with HP-48 calculators playing video games and me stuck with guessing the calculators next random number out to 6 digits. So I wrote BLOCKDROP, the HP-28 version of TETRIS. To play BLOCKDROP, enter all of the programs below (yes, all of them!) and execute programs MBAG, MPIG, and TGEN. MBAG creates POKE with checksum :7F3E: and MPIG creates PEEK with checksum :05AD:. TGEN creates files SCREEN, GO, and FILL with checksums :5E81:, :AEF7:, and :3CEF:, respectively. Once you are sure that POKE, PEEK, SCREEN, GO, and FILL are entered correctly you can delete programs MBAG, MPIG, TGEN, SCGEN, GOGEN, and FIGEN. You may now play BLOCKDROP by running BLOCKDROP (pretty ingenious, huh). The following commands are used when playing: "1" -- Rotate object "2" -- Move left "5" -- Move right "3" -- Drop object to bottom "0" -- Pause game The calculator should be held sideways when you play the game, and unless you like a lot of extra variables in your game, don't press ON while BLOCKDROP is running. If you need to use another of the calculator's functions, press pause. When you wish to return to the game, go back to the directory where the program is and press CONT (shift-1). If you want to end the game, just let the blocks fall untill the screen is filled and you see the "GAME OVER" message. From there, hit any key and you will be back to the main screen with the message "GAME OVER" and your score on the stack. Although the game seems to move slower than a snail frozen in a glacier, it does run at twice the normal clock speed so don't play if your battery is low. I used four programs in this game that I did not write. My thanks to Alonzo Gariepy and the two anonymous programmers for their contri- butions. Although three of the programs say "Modified" after them, the modifications were small and did not in any way change the function of the program. For those of you without HP-28 calculators but still want to play BLOCKDROP, fear not! There are IBM, APPLE II, and COMMODORE-64 versions on the way. Have fun, and enjoy! MBAG [62D6] by Alonzo Gariepy (program modified) << << SWAP OVER # 0d AND OR SWAP # 60313793039700529d # 60312697556113217d # 60344589032298049d # 893930875306183944d # 60239021960728625d # 892347295072326737d # 14984791528145224318d >> HOME 'POKE' DUP PURGE STO # 3463884939656703126d # 851776d # 851953d SYSEV AL >> MPIG [E63F] by Alonzo Gariepy (program modified) << << RCWS SWAP 64 STWS # 0d OR SWAP STWS "ABCDEFGHIJKLMNOPQRSTUVWXYZ1" >> HOME 'PEEK' DUP PURGE STO # 3463884939532971158d # 851894d POKE # 1599169402857788225d # 851910d POKE # 3537372007626905445d # 851926d POKE # 3519005774320177d # 851942d POKE >> SPEED [3D91] Anonymous (program modified) << 'SPEED' -> s n << PATH RCWS 64 STWS s R->B # 15d AND # 281474976710656d * # 891716034201780 156d OR { # 4047118155055345d # 3519005774319921d } + HOME n RCL SWAP n PURGE n STO # 917431d SYSEVAL n STO STWS -> b << 1 b SIZE FOR a b a GET EVAL NEXT >> >> >> PS? [515B] Anonymous << SWAP # 1046592d IF OVER 68 >= THEN 416 + END SWAP 8 * + PEEK SWAP 2 SWAP ^ R->B AND DUP / B->R >> BLOCKDROP [55C8] << 0 'SCO' STO SCREEN DUP 'BSCR' STO ->LCD 1 SF 64 STWS WHILE 1 FS? REPEAT 2 SF (5,1) 'OB' STO 3 CF 2 'R' STO RAND 7 * 1 + IP 'OBJECT' STO 'SCO' 10 STO+ WHILE 2 FS? REPEAT 15 SPEED (0,1) 'OB' STO+ BSCR ->LCD IF CHECKD THEN 2 CF END 'OB' 0 CHECKD R->C STO- IF OB (5,1) == THEN 1 CF END "" 4 SF "" 'BUFF' STO WHILE 4 FS? REPEAT KEY -> k f << IF f 0 == THEN 4 CF END IF k "1" == k "2" == OR k "5" == OR k "3" == OR k "0" == OR THEN BUFF k + 'BUFF' STO END >> END BSCR ->LCD IF BUFF "" <> THEN 1 BUFF SIZE FOR n BUFF n n SUB -> k << IF k "0" == THEN DEPTH ->LIST 'STAK' STO HALT STAK LIST-> DROP ELSE IF k "2" == THEN OB CHECKL 0 R->C + 'OB' STO ELSE IF k "5" == THEN OB CHECKR 0 R->C - 'OB' STO ELSE IF k "3" == THEN BDROP 2 CF 3 SF ELSE 1 'R' STO+ 'R' R 4 > 4 * STO- 'R' CHECKD STO- 'R' R 1 < 4 * STO+ END END END END >> NEXT END (0,1) 'OB' STO+ IF CHECKD NOT THEN 2 SF END 'OB' (0,1) STO- PLT END PLT SCORE END 0 3 FOR n BSCR 137 n * 1 + 137 n * 96 + SUB GO n 1 + GET + BSCR 137 n * 117 + 137 n 1 + * SUB + NEXT + + + ->LCD "GAME OVER" SCO { BUFF STAK OB SCO BSCR S Q P BLOX TITL A OBJECT R } PURGE >> BDROP [FE29] << 1 'A' STO WHILE A 1 == REPEAT 'OB' (0,1) STO+ CHECKD NOT 'A' STO END 'OB' (0,1) STO- >> BLOK [F7ED] { { # 42949672974d # 14d } { # 343597383792d # 112d } { # 2748779070336d # 896d } { # 21990232562688d # 7168d } { # 175921860501504d # 57344d } { # 1407374884012032d # 458752d } { # 11258999072096256d # 3670016d } { # 90071992576770048d # 29360128d } { # 720575940614160384d # 234881024d } { # 5764607524913283072d # 1879048192d } } SH [4071] { [[ (0,-1) (0,0) (0,1) (0,2) ] [ (1,0) (0,0) (-1,0) (-2,0) ] [ (0,-1) (0,0) (0,1) (0,2) ] [ (1,0) (0,0) (-1,0) (-2,0) ]] [[ (0,-1) (0,0) (1,0) (1,1) ] [ (-1,1) (0,1) (0,0) (1,0) ] [ (0,-1) (0,0) (1,0) (1,1) ] [ (-1,1) (0,1) (0,0) (1,0) ]] [[ (1,-1) (1,0) (0,0) (0,1) ] [ (-1,-1) (0,-1) (0,0) (1,0) ] [ (1,-1) (1,0) (0,0) (0,1) ] [ (-1,-1) (0,-1) (0,0) (1,0) ]] [[ (0,-1) (0,0) (1,0) (0,1) ] [ (0,-1) (-1,0) (0,0) (1,0) ] [ (0,-1) (-1,0) (0,0) (0,1) ] [ (-1,0) (0,0) (1,0) (0,1) ]] [[ (0,-1) (1,-1) (0,0) (1,0) ] [ (0,-1) (1,-1) (0,0) (1,0) ] [ (0,-1) (1,-1) (0,0) (1,0) ] [ (0,-1) (1,-1) (0,0) (1,0) ]] [[ (0,-1) (0,0) (0,1) (-1,1) ] [ (1,0) (0,0) (-1,0) (1,1) ] [ (1,-1) (0,-1) (0,0) (0,1) ] [ (-1,0) (0,0) (1,0) (-1,-1) ]] [[ (0,-1) (0,0) (0,1) (1,1) ] [ (1,0) (0,0) (-1,0) (1,-1) ] [ (-1,-1) (0,-1) (0,0) (0,1) ] [ (-1,1) (1,0) (0,0) (-1,0) ]] } SC [485E] { 0 100 300 600 1000 } CHECKD [D229] << 1 4 FOR m SH OBJECT GET { R m } GET OB + DUP 'A' STO 3 * (0,74) + C->R SWAP PS? N OT IF A IM 21 == THEN DROP 0 END NEXT * * * NOT >> CHECKR [CC2E] << 1 4 FOR m SH OBJECT GET { R m } GET OB + 3 * (-3,74) + C->R SWAP PS? NOT NEXT * * * >> CHECKL [ED83] << 1 4 FOR m SH OBJECT GET { R m } GET OB + 3 * (1,74) + C->R SWAP PS? NOT NEXT * * * >> SCORE [43A8] << LCD-> DUP ->LCD -> s << s 1 76 SUB s 138 213 SUB s 275 350 SUB s 412 487 SUB 4 ->LIST 'TITL' STO s 77 137 SUB s 214 274 SUB s 351 411 SUB s 488 548 SUB 4 ->LIST 'BLOX' STO 63 'P' ST O 0 'Q' STO 1 'S' STO WHILE P 0 > REPEAT 'P' 3 STO- 1 4 FOR n BLOX n GET P P SUB NUM NEXT + + + 'A' STO WHILE A 1020 == REPEAT 1 'S' STO+ 1 4 FOR n FILL n GET BLOX n GET 1 P 3 - SUB + BLOX n GET P 1 + 61 SUB + BLOX SWAP n SWAP PUT 'BLOX' STO NEXT 1 4 FOR n BLOX n GET P P SUB NUM NEXT + + + 'A' STO END END SC S GET 'SCO' STO+ 1 4 FOR n TITL n GET BLOX n GET NEXT + + + + + + + DUP 'BSCR' STO ->LCD >> >> PLT [76F9] << BSCR ->LCD 1 4 FOR g SH OBJECT GET { R g } GET OB + C->R 3 * 73 + 8 * R->B # 1047008d + SWA P BLOK SWAP GET -> x p << 1 2 FOR m x m 1 - 16 * R->B + DUP PEEK p m GET OR SWAP POKE NEXT >> NEXT >> TGEN [F23C] << 1 4 FOR n 1 3 FOR m FIGEN n GET m GET CHR NEXT + + NEXT 4 ->LIST 'FILL' STO 1 4 FOR n "" 1 20 FOR m GOGEN n GET m GET CHR + NEXT NEXT 4 ->LIST 'GO' STO "" 1 548 FOR n SCGEN n GET CHR + NEXT 'SCREEN' STO >> SCGEN [EB7A] { 0 0 0 0 0 0 0 54 182 182 60 60 54 182 182 54 0 0 224 240 176 176 240 224 128 128 128 0 0 0 5 149 197 149 149 149 0 0 0 0 0 0 0 0 0 255 255 219 255 15 11 15 143 139 143 143 139 143 143 139 143 143 139 143 143 139 143 143 139 143 15 11 15 255 219 255 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 255 0 0 0 0 0 0 0 199 239 109 108 108 108 109 239 199 0 0 57 125 109 109 109 109 109 125 57 0 0 0 24 32 25 4 36 24 0 0 0 0 0 0 0 0 0 255 255 182 255 0 0 0 255 182 255 3 2 3 227 162 227 227 162 227 3 2 3 255 182 255 0 0 0 255 182 255 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 255 0 0 0 0 0 0 0 193 195 195 195 195 195 195 251 249 0 0 158 223 219 219 222 219 219 219 155 0 0 0 24 20 18 18 20 24 0 0 0 0 0 0 0 0 0 255 255 109 255 0 0 0 255 109 255 192 64 192 199 69 199 199 69 199 192 64 192 255 109 255 0 0 0 255 109 255 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 255 0 0 0 0 0 0 0 60 62 54 54 60 54 54 62 60 0 0 7 7 6 6 6 6 6 7 7 0 0 0 128 128 229 149 149 227 1 6 0 0 0 0 0 0 0 255 255 219 255 240 208 240 241 209 241 241 209 241 241 209 241 241 209 241 241 209 241 241 209 241 240 208 240 255 219 255 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 128 255 } GOGEN [DB85] { { 224 224 0 192 192 0 0 224 224 0 0 192 224 96 96 192 96 96 96 96 } { 139 219 251 251 219 219 219 219 219 0 0 251 251 195 243 243 195 195 251 251 } { 8 156 156 54 182 190 182 182 54 0 0 54 182 182 182 182 182 190 156 8 } { 7 15 13 12 15 15 13 15 7 0 0 7 15 13 13 13 13 13 15 7 } } FIGEN [5D6C] { { 1 1 1 } { 0 0 0 } { 0 0 0 } { 128 128 128 } } David Still DESTILL@MTUS5.CTS.MTU.EDU