Generally SYNC prefers articles in some depth to help you get more out of your computer. However, we receive many short programs that illustrate a point, demonstrate a technique, or show something the reader has found interesting. “Just for Fun” shares these programs with you. If you learn something, great. If you have some fun, great. If you have some that you want to share, send them to: Just for Fun, SYNC, 39 E. Hanover Ave., Morris Plains, NJ 07950.
Bombsmash
M. Hampson
In Bombsmash the display shown in the sample run passes over your firing base from right to left. Your base remains stationary. You fire at the moving targets by pressing any key. If you hit a part of the letters or inverse asterisks, you get one point. Your goal is to wipe out all the targets in the display. However, if your shot misses all of the targets and continues to the top edge of the display, you lose.
The program is entered in three steps:
1) Type in
1 REM (followed by 32 characters)
2) Type in as direct commands the POKEs in Listing 1.
3) Type in Listing 2.
To play the game press RUN and ENTER. You fire by pressing any key. Your score will be displayed at the end of the game. The highest score is the best. Hit ENTER to start a new game.
Graphics notes:
20: A (32); set up display to show as in the listing; finish off with A(32).
31: inverse asterisk.
120: 6,W,4.
Reprinted from The Ultimate Magazine with permission.

Listing 1.
POKE 16514,42
POKE 16515,12
POKE 16516,64
POKE 16517,6
POKE 16518,24
POKE 16519,197
POKE 16520,35
POKE 16521,126
POKE 16522,50
POKE 16523,33
POKE 16524,64
POKE 16525,84
POKE 16526,93
POKE 16527,35
POKE 16528,1
POKE 16529,31
POKE 16530,0
POKE 16531,237
POKE 16532,176
POKE 16533,43
POKE 16534,58
POKE 16535,33
POKE 16536,64
POKE 16537,119
POKE 16538,35
POKE 16539,193
POKE 16540,16
POKE 16541,233
POKE 16542,201
Listing 2.
10 POKE 16418,0
20 PRINT "▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒";AT 15,5;"[block graphics forming the word 'bombsmash', see sample run]";AT 23,0;"▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒"
30 FOR Z=1 TO 50
31 PRINT AT INT (RND*10)+3,INT (RND*32);"[inv *]"
32 NEXT Z
40 LET B=0
50 LET S=0
100 PRINT AT 22,15;" "
110 RAND USR 16514
120 PRINT AT 22,15;"[g6][gW][g4]"
130 IF NOT B THEN GOTO 200
135 LET P=P-1
140 PRINT AT P,16;
150 LET N=PEEK (PEEK 16398+256*PEEK 16399)
155 PRINT "*"
160 IF N=8 THEN GOTO 300
170 IF N THEN GOTO 400
180 PRINT AT P,16;" "
190 GOTO 100
200 IF INKEY$="" THEN GOTO 100
210 LET P=22
220 LET B=1
230 GOTO 100
300 PRINT AT 1,1;"GAME OVER:YOUR SCORE>>>>";S
310 IF INKEY$<>CHR$ 118 THEN GOTO 310
320 CLS
330 RUN
400 LET S=S+1
410 LET B=0
420 GOTO 180
Space Pirate Attack
Sheldon Maloff
After a very successful mining operation in the asteroid belt, you are on the way back to your base to unload and resupply for the next expedition. Suddenly, you are attacked by a fleet of pirates. Although you are outnumbered 20 to 1, you have a chance because your position is such that they cannot attack you simultaneously. It all depends now on your skill and a little bit of luck. Your defense screen displays the field of attack. The radar will locate the pirate ship and show its location by displaying a number from 0 to 9. To fire you must press the corresponding key on your firing control console. If you are fast enough, you will score a hit. If you press the wrong key or do not fire at all, you will miss the pirate. In a fraction of a second the next pirate will appear on your screen. When all the twenty have appeared, the game ends and your score is displayed.
When you have entered the program, press RUN and ENTER. The playing grid consisting of colons will then appear on your screen. As soon as this grid is complete, the game starts. So be ready. A number from 0 to 9 will appear somewhere on the field. Press the same number on the keyboard to fire.
After the game is over, the field will be displayed. The periods represent the place where you destroyed a pirate ship. The pirates who escaped are shown by plus signs. The pirates that you were not fast enough to hit or that you did not shoot at are shown as numbers.
The computer randomly selects a time between 0.1 and 1.0 seconds when you press a firing button. The game thus combines the elements of skill and randomness that a good game must have.
Graphics notes:
5: PIRATES (inverse).
80: X (inverse).
1 LET S=0
5 PRINT AT 11,0;"[inv PIRATES]"
10 FOR R=0 TO 9
15 FOR C=0 TO 9
20 PRINT AT R,C;":"
25 NEXT C
30 NEXT R
35 FOR C=1 TO 20
40 LET X=INT (RND*10)
45 LET Y=INT (RND*10)
50 PRINT AT X,Y;CHR$ (X+28)
55 FOR R=1 TO 40*RND
60 LET Q=CODE INKEY$-28
65 IF Q<>-28 THEN LET R=100
70 NEXT R
75 IF Q<0 THEN GOTO 95
80 PRINT AT Q,Y;"[inv X]"
85 IF X=Q THEN LET S=S+1
90 PRINT AT X,Y;"+";AT Q,Y;"."
95 NEXT C
100 PRINT AT 10,0;"S=";S
Space Age Graphics
Robert G. Boyer
Keith Comer’s article in SYNC 1:3 on graphics intrigued me, so I wanted to use it on my ZX80 with the 8K ROM. The conversion involved only a few changes in the program lines. However, the 4K and 8K ROMs have different codes for the characters. To convert a 4K ROM picture to the 8K ROM requires getting the character equivalents set up. The two lists are given in Table 1. If you are going to translate a picture, follow this table. However, you can start from scratch with your own ZX81 or T/S 1000.
To use the system, turn to “The Character Set” chapter in your manual. Put the letters A-J beside characters 1-10 and M-V beside characters 129-138. The inverse space becomes the letter L.
If you do not have the original article, get a sheet of graph paper. Lightly rule every other line horizontally and vertically so that you will have blocks divided into four smaller blocks. Each of the larger blocks represents a full character space on the computer. Now draw your picture by shading the small blocks. You can use solid black, grey, and white (by leaving a blank). When you are finished, look at the larger blocks and note which of the various pixel arrangements in the character set looks just like that four block unit. Enter the letter for that character into your string. Do not forget to indicate white spaces. The pound sign (found on the shifted space key) indicates the end of the line.
You are converting your picture to a string which the computer will display as a picture using the graphics characters. With 16K RAM the possibilities for this program are endless.
Listing 1 gives the program for storing and producing your picture. A sample picture is given in line 10 in the A$ string. If you are developing your own picture, enter the letters into the A$ string in line 10. Type in the program, press RUN and ENTER. As you may guess when you see the picture, I work for NASA.
Figure 1. Character Sets.
4K ROM 8K ROM 2 5 3 131 4 1 5 2 6 4 7 135 8 6 9 8 10 9 11 11 130 133 131 3 132 129 133 130 134 132 135 7 136 134 137 136 139 138
Listing 1
10 LET A$="35OO£3BDIR£4BDIRD£5MDIBR£4Q5ROOOOOOOOCCOD£45A88BR£4RQ78SOF£45RD8OOOCCCA£5AF5SFC£5AF5SFC£6E3OCA£6CCCC£"
20 LET X=CODE A$
30 IF X=12 THEN PRINT
40 IF X=12 THEN GOTO 80
45 IF X<38 THEN GOTO 110
50 IF X<48 THEN LET X=X-37
55 IF X=48 THEN LET X=X+80
60 IF X>47 THEN LET X=X+79
70 PRINT CHR$ X;
80 LET A$=A$(2 TO )
90 IF A$="" THEN GOTO 145
100 GOTO 20
110 FOR N=1 TO X-28
120 PRINT " ";
130 NEXT N
140 GOTO 80
Driver
Neil Dewhurst
In Driver you are at the wheel of a race car on a hazardous race course. This is a test of your driving skills. You must avoid the obstacles as you speed toward to finish line. The car heads left by itself. Pressing any key makes it head the other way. Your score is displayed when you crash. Pressing any key restarts the game.
This program uses the graphics capabilities of the ZX81 to create the screen display of a road and the obstacles along the way. The SCROLL feature produces a moving course. The INKEY$ function allows the input of any key for control.
Graphics notes:
40: G
70: H
To make the game more difficult, change line 40 as indicated at the end of the listing.
Reprinted from The Ultimate Magazine with permission.
10 LET P=16
20 LET S=0
30 SCROLL
40 PRINT "[gG]";TAB INT (RND*19)+1;"[gG]";TAB 20;"[gG]"
50 PRINT AT 10,P;
60 IF 137=PEEK (PEEK 16398+256*PEEK 16399) THEN GOTO 100
70 PRINT "[gH]"
80 LET S=S+1
90 LET P=P+1-(INKEY$="")*2
99 GOTO 30
100 PRINT S
110 PAUSE 4E4
120 GOTO 20
40 PRINT "[gG]";TAB INT (RND*12)+1;"[gG] [gG]";TAB 20;"[gG]"
Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.