10 REM - BURGLAR.BAS.txt

20 GOSUB 1000 : REM Clear the Screen
30 PI = 3.14159
40 DZOP "C",1 : REM Color mode [Range = 16-23]
50 XC = 128 : YC = 128 : REM Initial center of the skull
60 REM Set initial colors for the SKULL parts
70 SC = 23 : REM Initial skull color (White for the skull)
80 BC = 17 : REM Initial bone color (Red for the crossbones)
90 EC = 19 : REM Initial feature color (Black for eyes, nose, mouth)
100 FOR STEPS = 1 TO 1000 : REM Loop to keep SKULL wandering
110 GOSUB 4000 : REM Move the skull to a new random position
120 GOSUB 2000 : REM Draw the SKULL and crossbones with changing colors
130 GOSUB 3000 : REM Pause between moves
140 GOSUB 5000 : REM Update the color scheme for the next iteration
150 GOSUB 1000 : REM Clear the screen for the next position
160 NEXT STEPS
999 GOTO 10 : REM Loop back to the beginning for continuous run

1000 REM Clear the Screen Routine
1010 DZOP "Z"
1040 RETURN

2000 REM SKULL AND CROSSBONES Drawing Routine
2010 DZOP "C",SC : REM Set color for skull
2020 GOSUB 2100 : REM Draw skull shape
2030 DZOP "C",BC : REM Set color for crossbones
2040 GOSUB 2200 : REM Draw crossbones
2050 DZOP "C",EC : REM Set color for skull features (eyes, nose, mouth)
2060 GOSUB 2300 : REM Draw skull features
2095 RETURN

2100 REM Draw Skull Shape (Rounded top, wider jaw, slight flare)
2110 FOR T = 0 TO (2*PI) STEP .1
2120 X = XC + 50 * COS(T) : Y = YC + 60 * SIN(T) + 10*SIN(T) : REM Shape for skull
2130 IF X >= 0 AND X <= 255 AND Y >= 0 AND Y <= 255 THEN DZOP "P", X,Y : DZOP "D"
2140 NEXT T
2150 RETURN

2200 REM Draw Crossbones (Two diagonal bones crossing below the skull)
2210 REM First Bone (from bottom left to top right)
2220 DZOP "P", XC-40,YC-40 : DZOP "L",XC+40,YC+40 : REM Diagonal bone 1
2230 REM Second Bone (from bottom right to top left)
2240 DZOP "P", XC+40,YC-40 : DZOP "L",XC-40,YC+40 : REM Diagonal bone 2
2290 RETURN

2300 REM Draw Skull Features (Eyes, nose, mouth)
2310 REM Draw Eye Sockets (Circles)
2320 FOR T = 0 TO (2*PI) STEP .1
2330 X = XC - 20 + 10 * COS(T) : Y = YC + 10 + 10 * SIN(T) : IF X >= 0 AND X <= 255 AND Y >= 0 AND Y <= 255 THEN DZOP "P", X,Y : DZOP "D" : REM Left Eye
2340 X = XC + 20 + 10 * COS(T) : Y = YC + 10 + 10 * SIN(T) : IF X >= 0 AND X <= 255 AND Y >= 0 AND Y <= 255 THEN DZOP "P", X,Y : DZOP "D" : REM Right Eye
2350 NEXT T
2360 REM Draw Nose (Triangle)
2370 DZOP "P", XC-5,YC-10 : DZOP "L",XC+5,YC-10 : DZOP "L",XC,YC-20 : DZOP "L",XC-5,YC-10 : REM Nose shape
2380 REM Draw Teeth (Horizontal lines)
2390 DZOP "P", XC-15,YC-30 : DZOP "L",XC+15,YC-30 : REM First row of teeth
2400 DZOP "P", XC-15,YC-35 : DZOP "L",XC+15,YC-35 : REM Second row of teeth
2495 RETURN

3000 REM Pause Routine
3010 FOR PAUSE = 1 TO 300 : NEXT PAUSE : REM Short pause
3020 RETURN

4000 REM Move the SKULL to a new random position
4010 XC = INT(RND(1)*160) + 48 : YC = INT(RND(1)*160) + 48 : REM Random position within screen bounds
4020 RETURN

5000 REM Update the SKULL Color Scheme
5010 SC = SC + 1 : IF SC > 23 THEN SC = 17
5020 BC = BC + 1 : IF BC > 23 THEN BC = 17
5030 EC = EC + 1 : IF EC > 23 THEN EC = 17
5040 RETURN

9999 REM End of Program
10000 GOTO 10
