I'm writing my own version of pokemon on my calculator and I'm getting a domain error for no reason (i have posted the lbl that im getting the error under as the entire program is over 1000 lines). I would recommend copying the code and running it on your calculator to help figure out what's going on as its not very well organized. The error happens on line 52 when you select swap (in the menu), and try to switch two numbers (with enter and +) and Lteam has more than 10 numbers. There is also another error on line when trying to turn the page when Lteam has more than 10 numbers (with buttons ← and →)
(This was made for the ti84-CE on TI connect CE so some of the syntax might be a little different)
Lbl TS
ClrHome
Disp "SWAP? - 1
Disp "INFO? - 2
Disp "Quit? - 3
Input A
If A=3
Goto GH
If A=1
Then
ClrHome
1→O
For(O,1,6
Output(O,1,O
Output(O,2,".
End
If dim(⌊TEAM)≤10
Then
For(O,1,dim(⌊TEAM
Output(O,3,⌊TEAM(O
End
Else
For(O,1,10
Output(O,3,⌊TEAM(O
End
Output(10,6,">>"
End
9→V
1→U
1→D
1→W
1→V
1→Q
"Q is page number
Output(W,4,"<
While 1=1
getKey→P
If P=34
1+W→W
If W=min(dim(⌊TEAM),10)+1
1→W
If P=25
W-1→W
If W=0
min(dim(⌊TEAM),10→W
If P=45
Goto GH
If V≠W
Then
Output(W,4,"<
Output(V,4,"
W→V
End
If P=26 and dim(⌊TEAM)>10Q
Then
Q+1→Q
For(O,10(Q-1)+1,min(10Q,dim(⌊TEAM))
Output(O,3,⌊TEAM(O
End
End
If P=24 and Q>1
Then
Q-1→Q
For(O,10(Q-1)+1,10Q
Output(O,3,⌊TEAM(O)
End
End
If P=105
Then
V→S
Output(V,5,"<
End
If P=95
Then
⌊TEAM(V)→T
⌊TEAM(S)→⌊TEAM(V)
T→⌊TEAM(S)
For(V,1,min(dim(⌊TEAM),10
Output(V,5," ")
Output(V,3,⌊TEAM(V
End
End
End
End
If A=2
Then
1→Q
Goto IF
End