Jump to content

Photo

Raising Atlantis!


94 replies to this topic

#1 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • 625 posts
  • Location:Toledo, OH

Posted Thu Feb 25, 2010 9:37 AM

As reviewed in this month's Retrogaming Times Monthly, I'm planning to try to salvage the UK cassette game Atlantis, and bring it from cassette over into the modern, emulator-friendly world. I'm going to document the process for next month's RTM, if only so everyone can see my make-every-mistake-in-the-book-twice problem solving methods. :)

Right now, the loose plan is this:

1. Load the code from tape twice, saving half to a new tape each time.
2. Load those two segments with the disk drives on, then save each to disk.
3. Combine the two in Classic99 via paste.
4. Figure out what variables the program is reading from its separate data file, then write a small program to read those variables from the tape and save them to disk.
5. Rewrite the program code to read the variables from disk instead -- or, instead, just add that data to the program code itself.
6. Run the code through the "BXB" program, which should allow it to run in XB with its BASIC character sets intact.
7. Save the whole mess to disk, run it in emulator.
8. Enjoy the adulation and gratitude of millions.


IF I can get the program to load from tape with disk drives attached, I can skip 1-3 and just save the code to disk.

Any suggestions or advice on this undertaking are welcome. I am buried in work right now, but I'm going to try to carve out a few hours to do this project over the weekend.

Keith

Posted Image

#2 Opry99er OFFLINE  

Opry99er

    Quadrunner

  • 8,246 posts
  • Location:Cookeville, TN

Posted Thu Feb 25, 2010 10:34 AM

You should be able to just rip it to disk. I made a video I put on YouTube about a tape-disk-pc transfer--- maybe there are extenuating circumstances about this particular game program of which I am unaware, but a tape-->emulator transfer is a pretty straight forward process... This game looks cool!! Never seen it before!

Edited by Opry99er, Thu Feb 25, 2010 10:35 AM.


#3 Opry99er OFFLINE  

Opry99er

    Quadrunner

  • 8,246 posts
  • Location:Cookeville, TN

Posted Thu Feb 25, 2010 10:37 AM

In addition, once the program is transferred to disk, you can make the fonts look different too/-- even use a double dragon font or a colecovision one. :). It wouldn't change the game, just make it more aesthetically pleasing. :)

#4 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Feb 25, 2010 10:57 AM

I should have mentioned, the reason it loads variables from a tape file is because it takes up every square inch of real estate in RAM. You can't RUN it from BASIC with a disk system connected. I haven't tried to load it with disk connected yet.

If I can get it working in XB in Classic99, I'll leave further modifications to others. What do you have against square O's? ;)

#5 The Codex OFFLINE  

The Codex

    Dragonstomper

  • 573 posts
  • Location:Richmond, VA

Posted Thu Feb 25, 2010 11:07 AM

Fantastic, I am really looking forward to this one and hope you're able to pull it off. Let me know if I can help in any way, and good luck!

#6 retroclouds OFFLINE  

retroclouds

    Stargunner

  • 1,523 posts
  • Location:Germany

Posted Fri Feb 26, 2010 3:37 AM

Looking forward to this :D

#7 Opry99er OFFLINE  

Opry99er

    Quadrunner

  • 8,246 posts
  • Location:Cookeville, TN

Posted Sun Feb 28, 2010 8:09 AM

Keith---2 suggestions.

1) CF7+?
2) Win99/4a has a CS1 simulator. You could digitize the tape and load it up in Win994a

I'm sure you've already thought of all that... But also check out CS1er.com--- good stuff


Owen

#8 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Sun Feb 28, 2010 9:33 AM

OK, due to aforementioned work duties, this is NOT happening in time for the March issue of RTM. :( I did my article on Santa Paravia (see other thread) and turned it in, and I'll have to make a go of this next weekend. In the middle of a big work push right now, so everything else is having to wait (including the revisions to Herding Cats that I need to do).

Hopefully in the next couple weeks, it'll all fall into place and I'll be a coding and modifying machine. :)

#9 retroclouds OFFLINE  

retroclouds

    Stargunner

  • 1,523 posts
  • Location:Germany

Posted Sat Mar 27, 2010 1:27 AM

I think that the problem with Atlantis will be that it won't work if there any disk drives (or CF7+) connected to the console.
Most likely the game requires all of VDP memory (which it won't get as there are some disk buffers in VDP).

Just this morning I came accross an article in the Smart Programmer (february 1984), the trick for actually running the game from disk would be to use the Mini Memory module and some of it commands (SAVE MEMEXP2, OLD MEMEXP2) in combination with CALL LOAD(-31888,63,255) for turning the disk drives off.

I have no TI time at all today :( but will get back tomorrow with the article from the Smart Programmer.

Could be that an initial conversion program will be required for writing the BASIC program from >A000 to disk (that would be a one-time thing) and for the data files. Don't have the details on this yet.

Would help if the cassette file would be available as WAV for processing with CS1er ;)

#10 The Codex OFFLINE  

The Codex

    Dragonstomper

  • 573 posts
  • Location:Richmond, VA

Posted Sat Mar 27, 2010 11:02 AM

What you say? Not understand. Just want magic from box. Do dance, offer goat, paint face. Box give magic now! :P

#11 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Sat Mar 27, 2010 8:07 PM

I think that the problem with Atlantis will be that it won't work if there any disk drives (or CF7+) connected to the console.
Most likely the game requires all of VDP memory (which it won't get as there are some disk buffers in VDP).

Just this morning I came accross an article in the Smart Programmer (february 1984), the trick for actually running the game from disk would be to use the Mini Memory module and some of it commands (SAVE MEMEXP2, OLD MEMEXP2) in combination with CALL LOAD(-31888,63,255) for turning the disk drives off.

I have no TI time at all today :( but will get back tomorrow with the article from the Smart Programmer.

Could be that an initial conversion program will be required for writing the BASIC program from >A000 to disk (that would be a one-time thing) and for the data files. Don't have the details on this yet.

Would help if the cassette file would be available as WAV for processing with CS1er ;)





You expect me to know how to do any of that? :)

Do you see any reason for my original, somewhat cumbersome plan not to work? If I OLD CS1, delete some lines, then save it... then OLD CS1 again, delete the other lines, save THAT... then merge the two half-programs and run it through BXB to make it work in Extended BASIC. Suddenly we can access the 32K, problem is solved. Then we find out what the contents of the data file are that the program loads, replace that with hard-coded variables in a subroutine, and we're all set.

I'm hoping to get a bunch of this done tomorrow -- big project is over and I may have some TI time before the next wave of work submerges me.

#12 retroclouds OFFLINE  

retroclouds

    Stargunner

  • 1,523 posts
  • Location:Germany

Posted Sun Mar 28, 2010 3:26 AM

You expect me to know how to do any of that? :)

Do you see any reason for my original, somewhat cumbersome plan not to work? If I OLD CS1, delete some lines, then save it... then OLD CS1 again, delete the other lines, save THAT... then merge the two half-programs and run it through BXB to make it work in Extended BASIC. Suddenly we can access the 32K, problem is solved. Then we find out what the contents of the data file are that the program loads, replace that with hard-coded variables in a subroutine, and we're all set.

I'm hoping to get a bunch of this done tomorrow -- big project is over and I may have some TI time before the next wave of work submerges me.


ok, that's a good plan ;)

Think this may work.

Guess it mainly depends if the BASIC game uses character set 15 and 16, which aren't available in Extended Basic.
I don't know what BXB is. Is it used for dealing with the character set issue ?

Good luck :)

#13 retroclouds OFFLINE  

retroclouds

    Stargunner

  • 1,523 posts
  • Location:Germany

Posted Sun Mar 28, 2010 3:34 AM

Below is the article I mentioned yesterday. It is extracted from The Smart Programmer February 1984 and deals with Basic programs that are too large to run from disk.

A gentleman from Georgia recently asked us how to get a Basic program that is stored on disk and is too large to
run with the disk drives attached to run.

The problem was such that the program could be loaded into memory from the disk but it contains a large number of
numeric and string variables which eat up a lot of memory when the program is running. In Basic the computer does
not recognize Expansion Memory as a place to load programs so they must load and run from VDP RAM.
Unfortunately the disk buffer space is also in VDP RAM and uses up some of the space that may be necessary to run
large Basic programs. Even with the CALL FILES(1) command there is still aprox 500 bytes retained as a disk buffer
and this may be just enough to crash the program. The CALL LOAD, which is listed below, will shut off the disk drives
but in Basic you must type in NEW to open up the memory space.
Naturally whenever you type in NEW your program is cleared out of memory and that was the problem.

The solution requires the Mini-Memory module to be plugged in the cartridge port and Expansion Memory to be attached
and turned on. With the Mini-Mem in the port there are a few new commands added to the Basic language, even though
you have selected TI BASIC. The ones that we are concerned with are SAVE and OLD, MINIMEM, EXPMEM1, EXPMEM2 and out of
these we really only need SAVE and OLD EXPMEM2.

The procedure for running these large Basic programs from disk is as follows:

1. Power Up, select Basic and type in CALL INIT. This will initialize memory expansion and it will also clear out what
ever was stored in the Mini-Mem module. If you want to retain what is in the Mini-Mem just turn off the memory expansion
and then turn it back on and that will clear out without erasing the Mini-Mem.

2. Load the program you want to run from your disk. OLD DSK1.xxxxxxx

3. Type in SAVE EXPEM2 and press ENTER. This will copy the
program in VDP RAM into the expansion memory.

4. Type in CALL LOAD(-31888,63,255) and press ENTER. This tells the computer not to reserve any room in VDP RAM for the disk buffers.

5. Now type in NEW and press ENTER. You have just opened up the extra memory space in VDP RAM that the disk was reserving.
But since Basic does not recognize expansion memory your program is still intact in high exp-memory, addresses hex >A000 through >FFFF.

6. Just type in OLD EXPMEM2 and press ENTER and this will copy the program in the exp-memory back into the VDP RAM program area.
A copy of the program is still in the exp-memory and it will remain there until you turn off the exp-memory, save another program into
that space or type in CALL INIT. No, you can't MERGE Basic programs.

7. Type in RUN and press ENTER and the program should now run without giving you a MEMORY FULL ERROR.


We didn't use SAVE MINIMEM or SAVE EXPMEM1 because neither one of these spaces are large enough to store a large Basic Program, 12K+.
The MINIMEM space is 4K of RAM, the EXPMEM1 space is 8K of RAM and the EXPMEM2 is 24K of RAM. Also the EXPMEM1 space will allow you to
save a program out there but it doesn't like OLD EXPMEM1 so you can't bring it back. You can use any one of these three names in an OPEN
statement for files provided you are not linking to an assembly language subroutine in which case it is best to just use EXPMEM2 in your OPEN
statements for files.

The best solution, if you have exp-memory, is to rework the programs to allow them to be loaded directly into exp-memory via Extended Basic.
You will probably have to rework some of the CALL CHAR's, HCHAR's, VCHAR's and CALL COLOR's to compensate
for the lack of characters sets 15 and 16 in Extended Basic.
You will however find that they run a little faster and they are easier to edit in Extended Basic.


Edited by retroclouds, Sun Mar 28, 2010 3:38 AM.


#14 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Sun Mar 28, 2010 4:09 AM

You expect me to know how to do any of that? :)

Do you see any reason for my original, somewhat cumbersome plan not to work? If I OLD CS1, delete some lines, then save it... then OLD CS1 again, delete the other lines, save THAT... then merge the two half-programs and run it through BXB to make it work in Extended BASIC. Suddenly we can access the 32K, problem is solved. Then we find out what the contents of the data file are that the program loads, replace that with hard-coded variables in a subroutine, and we're all set.

I'm hoping to get a bunch of this done tomorrow -- big project is over and I may have some TI time before the next wave of work submerges me.


ok, that's a good plan ;)

Think this may work.

Guess it mainly depends if the BASIC game uses character set 15 and 16, which aren't available in Extended Basic.
I don't know what BXB is. Is it used for dealing with the character set issue ?

Good luck :)



The game does use sets 15 and 16. BXB is a program that allows you to run such sprite-free BASIC programs in XB while still using all 16 charsets. I haven't tried it yet, so I'm really hoping it works. I have a sick little one on my hands this weekend, so if she doesn't feel better when she wakes up this morning, my TI plans may be shot. We'll have to see how it goes. :/

#15 sometimes99er OFFLINE  

sometimes99er

    River Patroller

  • 3,852 posts
  • Location:Denmark

Posted Sun Mar 28, 2010 4:37 AM

-

Edited by sometimes99er, Wed Sep 12, 2012 10:51 AM.


#16 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Wed Mar 31, 2010 10:40 AM

I missed the deadline for this month's Retrogaming Times Monthly, so if you go there looking for an Atlantis article, you'll be sad. But fear not, I AM working on it, and hope to have some good news shortly. At the very least, I'm gonna have the program rescued from cassette before I leave for vacation, and hopefully I can then finish the rest of the conversion process via Classic99.

#17 The Codex OFFLINE  

The Codex

    Dragonstomper

  • 573 posts
  • Location:Richmond, VA

Posted Wed Mar 31, 2010 10:59 AM

That a bad-news-good-news kind of thing mate, sorry about the former but glad to hear about the latter. Here's wishing you good luck in your continued conservation/restoration efforts!

#18 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Apr 29, 2010 9:32 AM

BUMP!

I'm now, RIGHT NOW, in real time, as we speak, sitting down to work on Atlantis. I plan to post here as my efforts progress (or not). Wish me luck!

Step one: load game in BASIC, delete first half, save to CS1, load game again, delete second half, save to CS1. Then load each half, save to CF7, and move to Classic99.

After that, if I'm not already driven to drink, I'll break for lunch and move onward.

#19 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Apr 29, 2010 9:52 AM

OK, one early success. The game loaded successfully with the CF7 installed, and saved to DSK1 without incident. No lengthy deleting process necessary. It wouldn't have run properly, but I at least got it onto the CF7.

Next step - to download the "BXB" software which is supposed to make it work in Extended BASIC, and then print out the listing so I can extract the data from side two of the cassette and build it into the program listing itself, as opposed to being in an external file.

I may finish this sometime this year after all! :)

#20 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Apr 29, 2010 9:58 AM




1 REM  1

2 DIM X1(<img src='http://www.atariage.com/forums/public/style_emoticons/<#EMO_DIR#>/icon_cool.gif' class='bbc_emoticon' alt='8)' />,Y1(<img src='http://www.atariage.com/forums/public/style_emoticons/<#EMO_DIR#>/icon_cool.gif' class='bbc_emoticon' alt='8)' />,E$(<img src='http://www.atariage.com/forums/public/style_emoticons/<#EMO_DIR#>/icon_cool.gif' class='bbc_emoticon' alt='8)' />,X9(3),TY(3),TX(3),S1(2),AD(2),SF(2)

3 DEF YT=ASC(SEG$(CF$,F+3,1))

4 DEF YS=VAL(SEG$(CF$,F+4,3))

5 DEF YR(Q)=VAL(SEG$(T$,Q,2))

6 DEF YQ(Q)=VAL(SEG$(L6$,Q,1))

7 DEF YP=((1-0+1)*RND)+0

8 DEF YO(Q)=ASC(SEG$(L6$,Q,1))

9 DEF CA(Q)=ASC(SEG$(SE$,SY+Q,1))-60

10 DEF MO$(Q)=CHR$(Q+60)

11 DEF DG(Q)=SEG$(I$,M+Q,1)=SEG$(UI$,F,1)

12 DEF QW(Q)=ASC(SEG$(ER$,WF+Q,1))-60

13 DEF YU(Q)=ASC(SEG$(CF$,F+Q,1))-60

14 SA(0)=118

15 SA(2)=113

16 AD(0)=1

17 FH=1

18 SF(0)=115

19 SF(2)=113

20 CALL CLEAR

21 K$="QP A"

22 GH=1005

23 OPEN #1:"CS1",SEQUENTIAL,INTERNAL,INPUT,FIXED 190

24 CALL CLEAR

25 CALL SCREEN(2)

26 CALL COLOR(1,2,2)

27 FOR F=1 TO 3

28 INPUT #1:J$

29 PRINT J$: :

30 NEXT F

31 CALL CHAR(42,"00FF00FF00FF00FF")

32 CALL SCREEN(5)

33 CALL COLOR(1,5,5)

34 INPUT #1:ES$

35 INPUT #1:SE$

36 INPUT #1:RR$

37 EE$=ES$&SE$

38 FOR F=1 TO 8

39 INPUT #1:E$(F)

40 NEXT F

41 FOR F=0 TO 3

42 INPUT #1:TX(F),TY(F)

43 NEXT F

44 FOR F=0 TO 8

45 INPUT #1:X1(F),Y1(F)

46 NEXT F

47 FOR F=1 TO 34

48 INPUT #1:C$

49 CALL CHAR(VAL(SEG$(C$,1,3)),SEG$(C$,4,LEN(C$)-3))

50 NEXT F

51 INPUT #1:HL$

52 INPUT #1:I$

53 CLOSE #1

54 J$=""

55 CALL CLEAR

56 SF(0)=2

57 SF(2)=0

58 SN=0

59 TL=1

60 IO=18

61 IF SC<HI THEN 64

62 HI=SC

63 HG=0

64 TY$=STR$(HI)

65 SC=0

66 VV=1

67 C$=HL$

68 X=12

69 Y=15

70 SE$=EE$

71 ER$=RR$

72 B=3

73 A1=3

74 JK=99

75 W1=98

76 CB=0

77 LK$=""

78 L=13

79 T$="13102!LFZT"

80 IZ=1

81 GOSUB 446

82 T$="15103!KPZTUJDL"

83 GOSUB 446

84 T$="1809QSFTT!2!PS!3"

85 GOSUB 446

86 CALL KEY(0,K,S)

87 IF(K<>49)*(K<>50)THEN 86 ELSE 88

88 KY=K-48

89 FE=17

90 CALL CLEAR

91 CALL SCREEN(5)

92 FOR F=1 TO 16

93 CALL COLOR(F,5,5)

94 NEXT F

95 IZ=1

96 RESTORE 428

97 READ CF$

98 GOSUB 450

99 READ CF$

100 JK=L

101 W1=L

102 YL=56

103 GOSUB 450

104 RESTORE 427

105 GOSUB 440

106 RESTORE 426

107 CALL HCHAR(24,12,129,17)

108 CALL SCREEN(2)

109 FOR F=1 TO 8

110 READ C4,C5,C6

111 CALL COLOR(C4,C5,C6)

112 NEXT F

113 P=2

114 P1=11

115 GOSUB 436

116 IZ=0

117 IF W1=JK THEN 119

118 L=INT((28-13+1)*RND)+13

119 KK=28

120 GOSUB 413

121 EL=VAL(SEG$(STR$(L),1,1))

122 EL2=VAL(SEG$(STR$(L),2,1))

123 A2=1

124 FOR F=0 TO EL2

125 EL5=ASC(SEG$(E$(EL),A2,1))-60

126 A2=A2+EL5

127 NEXT F

128 L2$=SEG$(E$(EL),A2-EL5,EL5)

129 L6$=SEG$(L2$,6,(ASC(SEG$(L2$,1,1))-60)-5)

130 L9=LEN(L6$)

131 IF L<48 THEN 152

132 U=96

133 GOSUB 457

134 L9=VAL(SEG$(L6$,1,1))

135 FOR F=1 TO L9*4 STEP 4

136 FOR J=0 TO 3

137 X9(J)=YO(F+(J+1))-80

138 NEXT J

139 RANDOMIZE YQ(LEN(L6$))

140 IF X9(0)<0 THEN 148

141 FOR I=X9(0)TO X9(3)

142 CALL HCHAR(I,X9(1)+YP,32,X9(2)-YP)

143 NEXT I

144 NEXT F

145 CALL COLOR(1,8,5)

146 CALL COLOR(9,14,5)

147 GOTO 167

148 FOR I=ABS(X9(1))TO ABS(X9(2))

149 CALL VCHAR(ABS(X9(0))+YP,I,32,ABS(X9(3))-YP)

150 NEXT I

151 GOTO 144

152 U=32

153 GOSUB 457

154 FOR F=1 TO L9

155 ON YQ(F)GOSUB 378,391,393,403,405,403,405,411

156 NEXT F

157 IF(L<>46)*(L>=44)*(L<=47)THEN 158 ELSE 145

158 RESTORE 435

159 FOR F=1 TO EL2-3

160 READ RC,RB

161 NEXT F

162 RANDOMIZE 5

163 FOR F=10 TO 19

164 CALL HCHAR(F,RC+YP,32,RB-YP)

165 NEXT F

166 GOTO 145

167 CALL HCHAR(2+(TL*2),28,58)

168 CALL HCHAR(2+(EL*2),28,105)

169 FOR SY=1 TO LEN(SE$)STEP 5

170 IF CA(1)=L THEN 174

171 NEXT SY

172 ST=5

173 GOTO 194

174 MV=CA(0)

175 XF=CA(2)

176 YF=CA(3)

177 HJ=CA(4)

178 LI=CA(1)

179 SH=SA(MV+1)

180 RESTORE 431

181 FOR F=1 TO HJ

182 READ CR$

183 NEXT F

184 FOR F=0 TO 9

185 CALL CHAR(113+F,CR$)

186 READ CR$

187 NEXT F

188 RT=INT((16-3+1)*RND)+3

189 ST=1

190 CALL HCHAR(YF,XF,SH)

191 CALL HCHAR(YF,XF+1,SH+1)

192 CALL COLOR(11,RT,5)

193 CALL COLOR(12,RT,5)

194 FOR WF=1 TO LEN(ER$)STEP 4

195 IF QW(0)=L THEN 198

196 NEXT WF

197 GOTO 200

198 CALL HCHAR(QW(1),QW(2),QW(3))

199 CALL COLOR(2,16,5)

200 RO=0

201 IZ=0

202 IF(CB=1874)*(UI=56)THEN 335

203 XK=X

204 A9=A1

205 CALL GCHAR(X,Y,TK)

206 IF TK<>96 THEN 218

207 ON A9 GOTO 218,208,208,213,218,213,208,208

208 X=X+1

209 IF X<19 THEN 205

210 X=XK

211 A9=4

212 GOTO 205

213 X=X-1

214 IF X>3 THEN 205

215 X=XK

216 A9=2

217 GOTO 205

218 IF(T>0)*(T<8)THEN 256 ELSE 255

219 X=X-X1(A1)

220 Y=Y-Y1(A1)

221 ON POS("`+>@?=(*,!",CHR$(S),1)+1 GOTO 222,353,353,223,223,223,223,315,325,339,325

222 IF(S>113)*(S<122)THEN 353 ELSE 263

223 LO=ASC(SEG$(SEG$(L2$,2,4),(S-60),1))-60

224 IF(LO=L)+(L=0)THEN 263

225 CALL HCHAR(X,Y,32)

226 TL=EL

227 UY$=SEG$(SE$,1,SY-1)

228 UT$=SEG$(SE$,SY+5,LEN(SE$)-SY+5)

229 UI=LO

230 RESTORE 425

231 FOR F=1 TO 10 STEP 2

232 READ DK,FK

233 CALL COLOR(DK,FK,5)

234 NEXT F

235 IF TY(S-61)=0 THEN 237

236 Y=TY(S-61)

237 IF TX(S-61)=0 THEN 239

238 X=TX(S-61)

239 IF(AB=0)*(ST=5)THEN 248

240 IF AB=0 THEN 246

241 LI=ASC(SEG$(SEG$(L2$,2,4),(GC-60),1))-60

242 IF TY(GC-61)=0 THEN 244

243 XF=TY(GC-61)

244 IF TX(GC-61)=0 THEN 246

245 YF=TX(GC-61)

246 SE$=UY$&MO$(MV)&MO$(LI)&MO$(XF)&MO$(YF)&MO$(HJ)&UT$

247 AB=0

248 IF RO=0 THEN 253

249 WE$=SEG$(ER$,1,WF-1)

250 WW$=SEG$(ER$,WF,3)&CHR$(RO)

251 WR$=SEG$(ER$,WF+4,LEN(ER$)-WF+4)

252 ER$=WE$&WW$&WR$

253 L=LO

254 IF UI<50 THEN 121 ELSE 421

255 FOR T=1 TO 8

256 FOR F=1 TO B

257 IF B=3 THEN 263

258 X=X+X1(A1)

259 Y=Y+Y1(A1)

260 CALL GCHAR(X,Y,S)

261 IF S<>32 THEN 219

262 CALL HCHAR(X+(X1(A1)*-1),Y+(Y1(A1)*-1),32)

263 CALL HCHAR(X,Y,143+(A1*2)-1)

264 ON KY GOTO 295,298

265 CALL HCHAR(X,Y,143+(A1*2))

266 NEXT F

267 ON ST GOTO 268,305,310,302,278,272

268 CALL GCHAR(YF,XF+MV+AD(MV+1)+MV,S8)

269 IF(S8<>32)THEN 300

270 ST=6

271 GOTO 278

272 XF=XF+MV

273 CALL HCHAR(YF,XF+(MV*-1),32,2)

274 CALL HCHAR(YF,XF,SH+SN)

275 CALL HCHAR(YF,XF+1,SH+SN+1)

276 ST=1

277 SN=SF(SN)

278 NEXT T

279 IO=IO-1

280 CALL HCHAR(23,IO+12,92)

281 IF IO=0 THEN 365 ELSE 255

282 IF S<>32 THEN 219

283 A1=A1-1

284 IF A1>0 THEN 266

285 A1=8

286 GOTO 266

287 A1=A1+1

288 IF A1<9 THEN 266

289 A1=1

290 GOTO 266

291 B=3

292 GOTO 265

293 B=2

294 GOTO 265

295 CALL KEY(3,K,S)

296 IF S=0 THEN 265

297 ON POS(K$,CHR$(K),1)+1 GOTO 265,283,287,291,293

298 CALL JOYST(1,XJ,YJ)

299 ON POS("04@<",CHR$((((XJ*2)+(YJ))+<img src='http://www.atariage.com/forums/public/style_emoticons/<#EMO_DIR#>/icon_cool.gif' class='bbc_emoticon' alt='8)' />+48),1)+1 GOTO 265,283,293,287,291

300 ON POS("`>@?=",CHR$(S8),1)+1 GOTO 301,302,310,310,310,310

301 IF((S8>144)*(S8<159))THEN 357

302 MV=MV*-1

303 ST=2

304 GOTO 255

305 CALL HCHAR(YF,XF+SGN(1-(MV*-1)),SH+AD((MV*-1)+1))

306 CALL HCHAR(YF,XF+SGN((MV*-1)+1),SH+4)

307 ST=1

308 SH=SA(MV+1)

309 GOTO 255

310 GC=S8

311 AB=1

312 CALL HCHAR(YF,XF,32,2)

313 ST=5

314 GOTO 255

315 RO=101

316 B=3

317 SC=SC+100

318 CALL HCHAR(QW(1),QW(2),41)

319 HG=HG+1

320 CALL SOUND(10,4000,0)

321 KK=16

322 TY$=STR$(SC)

323 GOSUB 413

324 IF(T>0)*(T<8)THEN 256 ELSE 255

325 B=3

326 FOR F=IO TO 17

327 CALL SOUND(-100,-7,0)

328 CALL HCHAR(23,11+F,104)

329 NEXT F

330 IO=17

331 IF S=33 THEN 255

332 CALL HCHAR(QW(1),QW(2),43)

333 RO=103

334 GOTO 255

335 T$="0810"&C$

336 GOSUB 446

337 C$=HL$

338 GOTO 56

339 CALL SOUND(30,1000,0)

340 CALL HCHAR(QW(1),QW(2),32)

341 RO=92

342 SC=SC+200

343 HG=HG+1

344 GOTO 321

345 FE=FE-1

346 CALL HCHAR(24,13+FE-1,60)

347 FOR F=FE/2 TO 1 STEP-1

348 CALL SOUND(2,1500,5)

349 NEXT F

350 IF FE=0 THEN 352

351 B=3

352 RETURN

353 GOSUB 345

354 IF FE=0 THEN 360

355 IF(S=96)+(S=43)THEN 255

356 IF ST<>2 THEN 302

357 GOSUB 345

358 IF FE=0 THEN 360

359 IF ST<>2 THEN 302 ELSE 255

360 CALL SOUND(4000,1500,5)

361 T$="1007OP=MJGF=EFUFDUFE"

362 IZ=1

363 GOSUB 446

364 GOTO 56

365 T$="1010TVGGPDBUJPO"

366 IZ=1

367 GOSUB 446

368 GOTO 56

369 GOSUB 371

370 RETURN

371 AC$=""

372 FOR F=1 TO 11

373 AC$=AC$&CHR$(ASC(SEG$(C$,F,1))+(UI*VV))

374 NEXT F

375 C$=AC$

376 VV=VV*-1

377 RETURN

378 FOR I=2 TO 8

379 CALL HCHAR(I,4,33,23)

380 NEXT I

381 RETURN

382 RANDOMIZE YQ(F+1)

383 H1=0

384 FOR I=H5 TO 30-H5 STEP SGN((30-H5)-H5)

385 H=YP+H1

386 CALL VCHAR(20-H,I,96,H)

387 H1=H1+(YO(F+2)/100)

388 NEXT I

389 F=F+2

390 RETURN

391 H5=4

392 GOTO 382

393 H5=26

394 GOTO 382

395 RANDOMIZE YQ(F+1)

396 H1=YO(F+2)-60

397 FOR I=H5 TO 15 STEP SGN(15-H5)

398 H=((H1-(H1/2)+1)*RND)+(H1/2)

399 ON YQ(F)GOSUB 2,2,2,407,407,409,409

400 NEXT I

401 F=F+2

402 RETURN

403 H5=4

404 GOTO 395

405 H5=26

406 GOTO 395

407 CALL VCHAR(20-H,I,96,H)

408 RETURN

409 CALL VCHAR(2,I,96,H)

410 RETURN

411 CALL VCHAR(2,26,96,18)

412 RETURN

413 TP=KK-LEN(TY$)

414 IF HG<>26 THEN 417

415 ER$=RR$

416 HG=0

417 FOR F=1 TO LEN(TY$)

418 CALL HCHAR(21,TP+F,ASC(SEG$(TY$,F,1)))

419 NEXT F

420 RETURN

421 CB=CB+UI

422 IF CB>1900 THEN 121

423 GOSUB 369

424 GOTO 121

425 DATA 2,5,11,5,12,5,9,5,1,5

426 DATA 16,2,5,15,2,5,1,8,5,3,2,11,4,2,11,10,11,5,2,16,5,13,7,11

427 DATA 9,"2104TDPSF=111111","2119IJ=111111","2304PYZHFO","0528E","0828F","1128Q","1428U","1728I","2404FOFSHZ"

428 DATA "*==@073*=W@150+==@033+P=@165+Q@<026+R@<026+S@<026+T@<026*>X<018*>Y<018"

429 DATA "+SHh017*?X:016+=@=024+P@>024*=W?020"

430 DATA 19,0,2,0,0,4,0,25

431 DATA "80C0E7DF8702","80C0FEFFF8","00000187DFE7C380","0080C0FEF7FC","84CEF5FFF1110E","01037FEF3F"

432 DATA "0103E7FBE14","0000017FEF3F","0080C0E1FBE7C301","2173AFDF8F885020","F00EE31C01E21C"

433 DATA "1C3AE7E73A1C","000700001F00030C","00C62FBD5D1D2FC6","3C7EE7C3C3E77E3C"

434 DATA "385CE7E65D38","00F30CC03C837807","0063B4BBBCB8B463","00E000C0300020C0","3C66C38981C3673C"

435 DATA 8,4,13,4,0,0,13,6

436 FOR F=5 TO 8

437 CALL COLOR(F,P,P1)

438 NEXT F

439 RETURN

440 READ A

441 FOR F=1 TO A

442 READ T$

443 GOSUB 446

444 NEXT F

445 RETURN

446 FOR I=5 TO LEN(T$)

447 CALL HCHAR(YR(1),YR(3)+I-4,ASC(SEG$(T$,I,1))-IZ)

448 NEXT I

449 RETURN

450 FOR F=1 TO LEN(CF$)STEP 7

451 IF SEG$(CF$,F,1)="*" THEN 454

452 CALL HCHAR(YU(1),YU(2),YT,YS)

453 GOTO 455

454 CALL VCHAR(YU(1),YU(2),YT,YS)

455 NEXT F

456 RETURN

457 FOR F=2 TO 19

458 CALL HCHAR(F,4,U,23)

459 NEXT F

460 RETURN







#21 The Codex OFFLINE  

The Codex

    Dragonstomper

  • 573 posts
  • Location:Richmond, VA

Posted Thu Apr 29, 2010 10:17 AM

Superb! Well done so far man. That's not the whole program there, is it? If so, I'm even more impressed with what the programmers did.

#22 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Apr 29, 2010 10:31 AM

That would be it! I look forward to delving into its guts a bit more once it's running in XB, it looks like insanely well thought out and ruthlessly efficient code. I can't wait for you guys to see this game in action, even in agonizing BASIC speeds it's impressive as hell.

I got the BXB routines pasted in via the PASTE feature in Classic99 (a little bit of a cheat, I guess, not MERGE-ing it, but the goal here is getting it to work, not being pure to original methods). Next up, extracting all that data from the original data file. Shouldn't take me too long.

I have to knock off at 2 for an interview, but I'll be back at this later on. I'd love to have it done by tonight!

#23 The Codex OFFLINE  

The Codex

    Dragonstomper

  • 573 posts
  • Location:Richmond, VA

Posted Thu Apr 29, 2010 10:35 AM

Man alive, that's great! I hope to check it out tonight myself, at least in a code forensics kind of way. Seriously tight code, it's a good thing we weren't up against those guys in the 30-line competition. :)

Edited by The Codex, Thu Apr 29, 2010 10:37 AM.


#24 Opry99er OFFLINE  

Opry99er

    Quadrunner

  • 8,246 posts
  • Location:Cookeville, TN

Posted Thu Apr 29, 2010 10:45 AM

A 30 line console BASIC contest..... Print loop pong would be the best thing we could get. :) Not having access to multiple statement lines, I'd love to see a "good" 30/10 console BASIC game. :) Although, Adamantyr's idea for a tape loaded console BASIC game is pretty exciting. I might pull out my old BASIC shoes and go for a walk. :)

#25 InfernalKeith OFFLINE  

InfernalKeith

    Dragonstomper

  • Topic Starter
  • 625 posts
  • Location:Toledo, OH

Posted Thu Apr 29, 2010 10:50 AM

A 30 line console BASIC contest..... Print loop pong would be the best thing we could get. :) Not having access to multiple statement lines, I'd love to see a "good" 30/10 console BASIC game. :) Although, Adamantyr's idea for a tape loaded console BASIC game is pretty exciting. I might pull out my old BASIC shoes and go for a walk. :)


I can hear the old guys now. "You know what we called OUR 'thirty line programming contest'? OUR ENTIRE CAREER! We did everything in 3.2K with half of that reserved for an 8" disk driver that someone forgot to remove from the beta code! AND WE LIKED IT!!!! We programmed uphill both ways!! In snow!!!"

Actually, a big hero of mine in these matters is Jeffrey Daniels, over at the Denial Vic 20 forum. He recently released a collection of six games that run on an unexpanded 3K (!!!) Vic-20 in BASIC, and every game is a keeper. Of course, Vic BASIC is Indy 500 fast compared to TI console BASIC... :(




0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users