--learn japanese
white = Color.new(255,255,255)
menu = Image.load("images/menu.png")
lesson1menu = Image.load("images/lesson1menu.png")
page1 = Image.load("images/lesson1/page1.png")
page2 = Image.load("images/lesson1/page2.png")
page3 = Image.load("images/lesson1/page3.png")
page4 = Image.load("images/lesson1/page4.png")
page5 = Image.load("images/lesson1/page5.png")
page6 = Image.load("images/lesson1/page6.png")
page7 = Image.load("images/lesson1/page7.png")
page8 = Image.load("images/lesson1/page8.png")
page9 = Image.load("images/lesson1/page9.png")
page10 = Image.load("images/lesson1/page10.png")
lessoncomplete = Image.load("images/lessoncompletedefault.png ")
menuon = true
page1 = false
page2 = false
page3 = false
page4 = false
page5 = false
page6 = false
page7 = false
page8 = false
page9 = false
page10 = false
lessondone = false
while true do
screen:clear(white)
pad = Controls.read()
if pad:cross() and menuon = true then
screen:clear(white)
page1 = true
end
--page1
if pad:r() and page1 = true then
screen:clear(white)
page1 = false
page2 = true
end
if pad:l() and page1 = true then
screen:clear(white)
page1 = true
page2 = false
end
--images
if page1 = true then
screen:blit(0,0,page1)
end
if page2 = true then
screen:blit(0,0,page2)
end
if pad:cross() and lessondone = "true" then dofile quiz1.lua() end
if pad:circle() and lessondone = "true" then dofile menu.lua() end
screen:blit(0,0,menu)
screen:blit(183,88,lesson 1menu)
screen.waitVblankStart()
screen.flip()
end
i keep getting the error line 35: 'then' expected near '=' help?
what my code says is, im at the menu, and if "X" is pressed show me page 1, and while im on page one if "R" is press show me page 2 but if "L" is pressed then send me back to page 1
haha, someone 'borrow' it, you don't know japanese!!! j/k
(This post was last modified: 02/04/2008 11:33 PM by ZiNgA BuRgA.)
02/04/2008 01:22 AM
ZiNgA BuRgA
Smart Alternative
Posts: 17,022.2988 Threads: 1,174
Joined: 19th Jan 2007
Reputation: -1.71391 E-Pigs: 446.1274