Hey, I have a ti-83 plus, and i made this program. Unfortunately, it always lags out and I always get ERR:MEMORY after a few "bombs" have dropped.
I need suggestions to make it more efficient.
Btw, I'm far from a complex programmer, so plz explain any higher than average program suggestions.
Code:
I need suggestions to make it more efficient.
Btw, I'm far from a complex programmer, so plz explain any higher than average program suggestions.
Code:
:ClrHome
:Output(1,4,"CALCULATOR"
:Output(2,6,"BOMBER"
:Output(7,4,"PRESS ENTER"
:Pause
:ClrHome
:Output(1,5,"CONTROLS"
:Output(3,1,"LEFT AND RIGHT"
:Output(4,1,"ARROWS MOVE"
:Output(6,1,"EXIT- CLEAR"
:Output(7,1,"DROP BOMBS- 2ND"
:Pause
:ClrHome
:7→X
:0→S
:Lbl 2
:Output(1,12," "
:Output(8,14," "
:1→W
:Lbl 1
:While 1
:Output(2,X,"(*)"
:Output(8,W," <=>"
:W+1→W
:If W=14
:Goto 2
:getKey→K
:If K=24
:Goto LT
:If K=26
:Goto RT
:If K=21
:Goto BO
:If K=45
:Goto EX
:End
:End
:Lbl LT
:X-1→X
:If X<1:Then
:14→X
:Output(2,1," "
:Goto 1
:Else
:Output(2,1," "
:End
:End
:Lbl RT
:X+1→X
:If X>14:Then
:1→X
:Output(2,1," "
:Goto 1
:Else
:Output(2,1," "
:End
:End
:Lbl BO
:X+1→B
:3→Y
:Lbl 3
:Output(Y-1,B," "
:Output(Y,B,"*"
:Output(8,W," <=>"
:Y+1→Y
:W+1→W
:If W=14:Then
:Output(8,14," "
:1→W
:Goto 3
:Else
:If Y=8:Then
:Output(Y-1,B," "
:Goto 4
:Else
:Goto 3
:Lbl 4
:If B=W+1:Then
:S+1→S
:Output(1,13," "
:Output(1,13,"HIT!"
:Output(8,1," "
:Output(1,1,"SCORE"
:Output(1,7,S
:1→W
:Goto 1
:Else
:Output(1,12," "
:Output(1,12,"MISS!"
:Goto 1
:End
:End
:Lbl EX
:ClrHome
:Output(1,1,"QUITTED"