Jump to content

sometimes99er

Recommended Posts

Here's a little TI Basic demo. It sets up a few colors and squares, and then plots them randomly to the screen. Originally designed to be the background for a move-up-and-down block game menu. The game itself was supposed to feature a little boy in a platform environment.

 

100 CALL CLEAR
110 CALL SCREEN(5)
120 A$="007E7E7E7E7E7E"
130 FOR A=0 TO 3
140 CALL CHAR(A*8+40,A$)
150 NEXT A
160 CALL COLOR(2,8,1)
170 CALL COLOR(3,6,1)
180 CALL COLOR(4,10,1)
190 CALL COLOR(5,15,1)
200 X=INT(RND*24)+1
210 Y=INT(RND*32)+1
220 C=INT(RND*4)*8+40
230 CALL HCHAR(X,Y,C)
240 GOTO 200

I took this to demo the speed of my TI Basic emulator called Strawberry (WIP with integers only etc.).

 

 

matthew180 also took this to show how one could do it in 9900 assembly.

 

It was also compiled using the Wilhelm's TI Basic Compiler.

 

Also done in MLC. See last part of post #3.

 

Edited by sometimes99er
Link to comment
Share on other sites

MLC Kaleidoscope version :

 

http://youtu.be/V0w8fV53T2o

 

Basic -> MLC ( 30000 chars in 42 sec ) :

 

http://youtu.be/-RLPBeGK_eQ

 

MLC Optimised ( display 30000 chars in 28.9 sec ) :

 

http://youtu.be/PkXWKsWlNNA

 

 

 

 

100 CALL CLEAR
$MLC F 110 10 3000

800 CALL CLEAR
810 CALL SCREEN(5)
820 A$="007E7E7E7E7E7E"
830 FOR A=0 TO 3
840 CALL CHAR(A*8+40,A$)
850 NEXT A
860 CALL COLOR(2,8,1)
870 CALL COLOR(3,6,1)
880 CALL COLOR(4,10,1)
890 CALL COLOR(5,15,1)

900 CALL LINK("ESSAI")
910 END

$ESSAI
NDO I 30000
RND
DIV Z 24
LET X Z
RND
DIV Z 32
LET Y Z
RND
DIV Z 4
LET C Z
INC X
INC Y
MUL C 8
ADD C 40
PUTCHAR X Y C
NLOOP

$$
$END

 

Kaleidoscope :

 

100 CALL CLEAR
$MLC F 110 10 3000
800 CALL CLEAR
810 CALL SCREEN(5)
820 A$="FFFFFFFFFFFFFFFF"
830 FOR A=0 TO 12
840 CALL CHAR(A*8+40,A$)
841 CALL COLOR(A+2,a+1,a+1)
850 NEXT A

900 CALL LINK("ESSAI")
910 END

$ESSAI
NDO I 30000
RND
DIV Z 12
LET X Z
RND
DIV Z 16
LET Y Z
RND
DIV Z 13
LET C Z
INC X
INC Y
MUL C 8
ADD C 40
LET A 24
LET B 32
SUB A X
SUB B Y
PUTCHAR X Y C
PUTCHAR A Y C
PUTCHAR X B C
PUTCHAR A B C
NLOOP
$$
$END

 

Optimised

 

100 CALL CLEAR
$MLC F 110 10 3000
800 CALL CLEAR
810 CALL SCREEN(5)
820 A$="007E7E7E7E7E7E"
830 FOR A=0 TO 3
840 CALL CHAR(A*8+40,A$)
850 NEXT A
860 CALL COLOR(2,8,1)
870 CALL COLOR(3,6,1)
880 CALL COLOR(4,10,1)
890 CALL COLOR(5,15,1)
900 CALL LINK("ESSAI")
910 END

$ESSAI
DIMTABLE E 10
PUTTABLE E(0) 136
PUTTABLE E(1) 144
PUTTABLE E(2) 152
PUTTABLE E(3) 160

NDO I 30000
RND
DIV Z 768
LET X Z
RND
DIV Z 4
ADD E Z
BMOVECTOV E 1 X
SUB E Z
NLOOP
$$
$END

Edited by rocky007
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...