Posted 27 November 2012 - 10:03 AM
selected = 0
maxEintrag = 3
selectedsymbol = ">> "
reboot = false
term.clear()
local menuEintrage = {"a","b","c","d","e"}
function draw()
print("")
x = 0
while not x == maxEintrag do
if selected == 0 then
print(fs.combine(selectedsymbol , menuEintrage[x]))
else
print(fs.combine("" , menuEintrage[x]))
end
x = x + 1
end
end
--------------------------------------------------------------------- All Lines below are "wrong" ( a "=" is expected)
repeate
none, key = os.pullEvent ("key")
if key == 208 then
selected = selected + 1
if selected > maxEintrag then
selected = 0
end
elseif key == 200 then
selected = selected - 1
if selected < 0 then
selected = maxEintrag
end
end
end
until reboot == true
Whats wrong ?
I tryed every thing and find no solution.
Sry for my bad English i am German ;D