and here is the listing.
[1]
( simple FIGmenu)
128 var Pos
000 var ?pos
: select
Pos @ 128 = if 1 23 at ." you picked 1" then
Pos @ 178 = if 1 23 at ." you picked 2" then
Pos @ 228 = if 1 23 at ." you picked 3" then
Pos @ 278 = if 1 23 at ." you picked 4" then
Pos @ 328 = if 1 23 at ." you picked 5" then
Pos @ 378 = if 1 23 at ." Quit selected BYE!" quit then ;
( put what you like to happen in this part i.e. say xx load xx)
[2]
( the menu)
: screen cls
22 1 do 1 i at 160 emit 23 i at 160 emit loop
24 1 do i 1 at 160 emit i 22 at 160 emit loop ;
: options
7 2 at ." Simple Menu"
4 5 at ." 1)Opt one"
4 7 at ." 2)Opt two"
4 9 at ." 3)Opt three"
4 11 at ." 4)Opt four"
4 13 at ." 5)Opt five"
4 15 at ." 6)Quit" ; ( put your options here)
[3]
( move cursor)
: cursor 62 vram Pos @ + ic! ;
: nocursor 32 vram Pos @ + ic! ;
: down Pos @ 50 + Pos ! ;
: up Pos @ 50 - Pos ! ;
: checkDown ( gone too far? )
?pos @ 379 > if nocursor 376 Pos ! cursor then ;
: checkUp ( gone too far)
?pos @ 127 < if nocusor 128 Pos ! cursor then ;
: dokey ( move the cursor with U/D select with space)
inkey
dup 10 = if nocusor down cursor then
dup 11 = if nocursor up cursor then
32 = if select then ;
( run)
: init
128 ?pos !
128 Pos !
screen options cursor
begin
Pos @ ?pos !
checkDown
checkUp
dokey
Pos @ 500 = until ;