Script error 60 unexpected symbol
Code: Select all
blue = color.new(0,0,255)
white = color.new(255,255,255)
black = color.new(0,0,0)
green = color.new(0,128,0)
background = image.create(480,272,green)
ms = 1
mms = 3
while true do
screen.clear()
controls.read()
background:blit(0,0)
if controls.press("square") then
music = sound.loop("music/Confusion on [REPEAT].mp3")
end
if controls.press("triangle") and music and sound.playing(music) then
music:loop()
end
if controls.press("up") then
ms = ms - 1
end
if controls.press("down") then
ms = ms + 1
end
if ms > mms then
ms = 1
elseif ms <= 0 then
ms = mms
end
mc = {white, white, white}
mc[ms] = blue
screen.print(98, 110, "GAME", mc[1])
screen.print(98, 125, "Controls", mc[2])
screen.print(98, 140, "EXIT", mc[3])
if controls.press("cross") and ms == 1 then
draw.fillrect(0, 0, 480, 272, black)
dofile("name.lua")
end
if controls.press("cross") and ms == 2 then
dofile("controls.lua")
end
if controls.press("cross") and ms == 3 then
os.exit()
end
if ms <= 0 then
ms = 3
end
if ms >= 4 then
ms = 1
end
screen.waitvblankstart()
screen.flip()
end