Jump to content
IGNORED

Swamp path blues: 10 line TI Basic fun


tibasic

Recommended Posts

I thought it would be fun, after reading the 10-line extended basic competition discussion, to see whether an unexpanded TI 10 line game could be written. This is what I came up with yesterday evening.

100 PRINT ::::"*** SWAMP PATH BLUES ***":::"DONT GET BOGGY FEET 1 & 3":::"F4 TO EXIT"::::TAB(24);"SCORE"::
110 CALL KEY(0,K,S)
120 X=X+(K-50)*ABS(S<>0)*ABS((K>48)*(K<52))
130 CALL VCHAR(24,X+8,42)
140 DIR=(RND>0.5)*2+1
150 X_R=X_R+DIR*ABS(((X_R+DIR)>-1)*((X_R+DIR)<18))
160 PRINT TAB(X_R+2);CHR$(30);TAB(X_R+10-INT(SC/30));CHR$(30);TAB(24);STR$(SC)
170 IF ((X+<(X_R+2+2))+((X+>(X_R+10-INT(SC/30)+2))THEN 170
180 SC=SC+1
190 GOTO 110

Keys are 1 and 3 for left and right to stay on the path. The path gets narrower as the game progresses. The game ends when you stray off the path and get stuck in the swamp. To play the game again press function+4 to exit the game and then type "RUN".

  • Like 8
Link to comment
Share on other sites

????

When I copied and pasted it worked fine. Be sure you have pasted it into TI BASIC.

Sorry never use TI Basic as RXB runs TI Basic faster then TI Basic does.

 

I created RXB for one of these reasons.

Edited by RXB
Link to comment
Share on other sites

I thought it would be fun, after reading the 10-line extended basic competition discussion, to see whether an unexpanded TI 10 line game could be written. This is what I came up with yesterday evening.

 

Keys are 1 and 3 for left and right to stay on the path. The path gets narrower as the game progresses. The game ends when you stray off the path and get stuck in the swamp. To play the game again press function+4 to exit the game and then type "RUN".

 

Nice. I would maybe have liked for the player to be placed 1 or 2 lines higher on the screen.

 

It seems to be the same run every time. If I let it run without user input (using the keys), this is the scores I get:

 

TI Basic

62 points.

 

TI Extended Basic

25 points.

Has different background color.

 

RXB 2015E

47 points.

Has different graphics.

 

As mentioned (in the title) the game was designed for TI Basic.

 

 

Link to comment
Share on other sites

 

Nice. I would maybe have liked for the player to be placed 1 or 2 lines higher on the screen.

 

It seems to be the same run every time. If I let it run without user input (using the keys), this is the scores I get:

 

TI Basic

62 points.

 

TI Extended Basic

25 points.

Has different background color.

 

RXB 2015E

47 points.

Has different graphics.

 

As mentioned (in the title) the game was designed for TI Basic.

 

 

RXB has a different cursor and full lower real lowercase with decendor letters like j or g or y.

Link to comment
Share on other sites

Thanks everyone for trying it!!

 

Below is something sometimes99er requested. The player is placed one line higher. As a consequence it leaves a trail along the path. That might be useful perhaps if you want to see why you strayed close to the edge.

 

Different runs could perhaps be created by adding, e.g. "10 RANDOMIZE". Alternatively, without breaking the 10 line rule, you could press F4 immediately after running the program then enter "RANDOMIZE" at the command line and then type "CONTINUE".

 

I'm not planning on entering the competition but I'm looking forward to seeing the entries and perhaps will be inspired to try an Extended Basic for something.

100 PRINT ::::"*** SWAMP PATH BLUES ***":::"DONT GET BOGGY FEET 1 & 3":::"F4 TO EXIT"::::TAB(24);"SCORE"::
110 CALL KEY(0,K,S)
120 X=X+(K-50)*ABS(S<>0)*ABS((K>48)*(K<52))
130 DIR=(RND>0.5)*2+1
140 X_R=X_R+DIR*ABS(((X_R+DIR)>-1)*((X_R+DIR)<18))
150 PRINT TAB(X_R+2);CHR$(30);TAB(X_R+10-INT(SC/30));CHR$(30);TAB(24);STR$(SC)
160 IF ((X+<(X_R+2+2))+((X+>(X_R+10-INT(SC/30)+2))THEN 160
170 CALL VCHAR(23,X+8,42)
180 SC=SC+1
190 GOTO 110
Edited by tibasic
  • Like 5
Link to comment
Share on other sites

 

I'm not planning on entering the competition but I'm looking forward to seeing the entries and perhaps will be inspired to try an Extended Basic for something.

 

Why not??? You are certainly one of the most creative TI BASIC programmer on this forum, and you already have an entry! I'm positive you will not be able to resist :D

  • Like 6
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...