I have made this code for all you people who are board of bad option lists.
X=
Y=
Width=
Length=
Rem set up the look at the correct position
sync on
load image "up.bmp",1
load image "mid.bmp",2
load image "down.bmp",3
load image "ok.bmp",4
load image "cancel.bmp",5
ink rgb(255,255,255),0
box x,y,x+width-17,y+47
paste image 1,x+(width-16),y
paste image 2,x+(width-16),y+16
paste image 3,x+(width-16),y+32
paste image 4,x,y+58
paste image 5,x+40,y+58
Rem look at the list
Dim list$(length)
load array "list",list$()
Rem print the list
out:
for a=1 to 3
ink rgb(255,255,255),0
box x,y,x+width-17,y+47
set cursor x,y+((a-1)*16)
if a+extra=pick then ink rgb(100,200,100),rgb(255,255,255) : print checklist string$(a+extra#) else ink 0,rgb(255,255,255) : print checklist string$(a+extra#)
next a
sync
return
Rem loop
do
if mouseclick()=1 then
mx=mousex()
my=mousey()
repeat
until mouseclick()=0
gosub click
endif
sync
loop
Rem Click
Click:
if mx>x and mxy and myx+width-16 and mxy and my0
extra=extra-1
gosub out
endif
if mx>x+width-16 and mxy+32 and myx and mxy+58 and my0
goto ending
endif
if mx>x+40 and mxy+58 and my