Skip to content

Commit 786eb0f

Browse files
committed
2,087 B headroom
1 parent 5997eb7 commit 786eb0f

1 file changed

Lines changed: 7 additions & 32 deletions

File tree

examples/trek-portable.bas

Lines changed: 7 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
' ** SUPER PLANET TREK PORTABLE VERSION **
1+
' ** SPACE BATTLE COMPUTER GAME PORTABLE VERSION **
22

33
' ** STATE MACHINE STATES **
44
ST_QUIT=0 : ST_NEWGAME=1 : ST_NEWQUAD=2 : ST_COMMAND=3 : ST_DEAD=4
@@ -23,9 +23,6 @@ OBJ_LUT$(4) = "*"
2323
' 0..63: initialized dict slot (allocated by dictnew)
2424
CMD_DICT=-1
2525

26-
' ** INITIALIZE COLOURS USED IN STRING PRINTS **
27-
InitColours()
28-
2926
' COURSE_VEC(9,2) = nav keypad deltas; DEVICE_DAMAGE(8) / DEVICE_NAME$(8) = ship systems
3027
dim GALAXY(8,8),COURSE_VEC(9,2),K(3,3),VISITED_GALAXY(8,8),DEVICE_DAMAGE(8),DEVICE_NAME$(8),QUAD(8,8)
3128
InitDeviceNames()
@@ -79,12 +76,9 @@ end function
7976

8077
' ** PRINT MISSION ORDERS **
8178
function PrintMissionOrders()
82-
if SPACESTATION_COUNT<>1 then X$="S" : X0$=" ARE "
79+
8380
cls()
84-
print "MISSION:"
85-
print "DESTROY THE ";GLONKIN_COUNT;" GLONKIN WARSHIPS"
86-
print "DATE ";GAME_DATE+MISSION_DAYS;". ";MISSION_DAYS;" DAYS REMAINING."
87-
print "THERE";X0$;SPACESTATION_COUNT;" SPACESTATION";X$;" AVAILABLE FOR RESUPPLY & REPAIRS"
81+
print "MISSION:\nENEMY SHIPS: "; GLONKIN_COUNT ;"\nDAYS REMAINING: "; MISSION_DAYS;"\nSPACESTATIONS: "; SPACESTATION_COUNT
8882
return
8983
end function
9084

@@ -166,8 +160,8 @@ function SetupGame()
166160
next I
167161

168162
if GLONKIN_COUNT>MISSION_DAYS then MISSION_DAYS=GLONKIN_COUNT+1
169-
ShowKey() : ' ** KEY TO SRS ICONS **
170-
ShowCommands() : ' ** USE THESE COMMANDS LIST **
163+
'ShowKey() : ' ** KEY TO SRS ICONS **
164+
'ShowCommands() : ' ** USE THESE COMMANDS LIST **
171165

172166

173167
' Guarantee at least one SPACESTATION and preserve original balancing tweak.
@@ -1342,14 +1336,8 @@ end function
13421336

13431337
' ** DIRECTION HELPER **
13441338
function ShowDirections()
1345-
print ""
1346-
print " ENTER A NUMBER 4 3 2"
1347-
print " BETWEEN 1 AND 9 . . ."
1348-
print " ..."
1349-
print " 5 ---*--- 1"
1350-
print " ..."
1351-
print " . . ."
1352-
print " 6 7 8"
1339+
print "\nENTER A NUMBER\nBETWEEN 1 AND 9"
1340+
print " 4 3 2\n . . .\n ...\n5 ---*--- 1\n ...\n . . .\n 6 7 8"
13531341
return
13541342
end function
13551343

@@ -1388,18 +1376,5 @@ function InitDeviceNames()
13881376
end function
13891377

13901378

1391-
' ** COLOURS FOR IN-GAME **
1392-
function InitColours()
1393-
ACOL$=""
1394-
BCOL$=""
1395-
CCOL$=""
1396-
DCOL$=""
1397-
ECOL$=""
1398-
FCOL$=""
1399-
GCOL$=""
1400-
HCOL$=""
1401-
ICOL$=""
1402-
return
1403-
end function
14041379

14051380

0 commit comments

Comments
 (0)