Friday, July 12, 2024

continued progress on the TI-99 Slots



logic and the code are pretty well flushed out and done. Still working on the graphics.

Here is the main loop of the code.
410 RANDOMIZE
420 CALL CLEAR
425 call hchar(11,13,91,8)
426 call hchar(14,13,103,8)
427 call hchar(12,13,114,8)
428 call hchar(13,13,114,8)
430 C=14
440 FOR I=1 TO 3
450 PIC(I)=INT(10*RND)+1
460 ON PIC(I) GOSUB 840,900,960,1020,1080,1140,1200,1260,1320,1380
470 C=C+2
480 NEXT I
490 REM Scoring
495 if PIC(1)=4 then 660
500 if PIC(1)<>PIC(2) then 520
510 if PIC(2)=PIC(3) then 700
520 if PIC(1)<>PIC(3) then 610
530 GOTO 650
610 TOTAL=TOTAL-10
620 print "SORRY! YOU LOSE!"
640 goto 770
650 TOTAL=TOTAL+40
655 print "YOU WON $40"
657 GOTO 770
660 TOTAL=TOTAL+20
665 print "LEMON - YOU WON $20!"
670 GOTO 770
700 REM Jack POT
710 if PIC(1)=1 Then 730
720 Goto 750
730 TOTAL=TOTAL+500
740 Print "JACKPOT! YOU WON $500"
745 GOTO 770
750 TOTAL=TOTAL+250
760 Print "JACKPOT! YOU WON $250"
770 print "CURRENT TOTAL: $";TOTAL
780 print "WANT TO PLAY AGAIN?"
790 PRINT "PRESS Y FOR YES"
800 CALL KEY(0,KEY,STATUS)
810 if STATUS=0 then 800
820 if KEY=89 then 410
830 End

No comments:

Post a Comment

Golf Discs and their numbers

In the post, I'm going to talk about the 5 primary characteristics of golf discs: Weight, Speed, Glide, Turn, and Fade (plus a couple ...