Heres my issue. at the the transition from (Pressing start to play) to (loading "intro) I dont want to use the command
"screen.waitVblankStart()"
because i dont want it to wait. I want it to stay there UNTILL I press start!!
what should I do to display "intro" (its a picture that takes up the whole screen) after I press start also.
So here is my code:
pink = Color.new(255, 0 , 153)
blue = Color.new(0 , 153, 255)
orange = Color.new(255, 102, 0)
gray = Color.new(153, 153, 153)
black = Color.new(0 , 0 , 0)
green = Color.new(0, 255, 0)
white = Color.new(225, 225, 225)
--*****LOADING SCREEN*****
screen:print(194, 136, "Loading: 0%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
intro = Image.load("abaddonsparrable/introscreen.png")
screen:print(194, 136, "Loading: 20%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
lvlone = Image.load("abaddonsparrable/levelone intro.png")
screen:print(194, 136, "Loading: 40%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
story = Image.load("abaddonsparrable/story.png")
screen:print(194, 136, "Loading: 60%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
choiceone = Image.load("abaddonsparrable/choice1.png")
screen:print(194, 136, "Loading: 80%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
screen:print(194, 136, "Loading: 100%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
screen:print(194, 136, "Press START to play", white)
screen.flip()
pad = Controls.read()
if pad:start() then
screen:clear()
screen:blit(0, 0, intro)
screen.flip()
end
lua n00b question.
Moderators: Shine, Insert_witty_name
- Legacyxero
- Posts: 23
- Joined: Fri Sep 12, 2008 4:42 am
- Legacyxero
- Posts: 23
- Joined: Fri Sep 12, 2008 4:42 am
-
- Posts: 31
- Joined: Wed Jul 09, 2008 7:50 am
Code: Select all
pink = Color.new(255, 0 , 153)
blue = Color.new(0 , 153, 255)
orange = Color.new(255, 102, 0)
gray = Color.new(153, 153, 153)
black = Color.new(0 , 0 , 0)
green = Color.new(0, 255, 0)
white = Color.new(225, 225, 225)
--*****LOADING SCREEN*****
screen:print(194, 136, "Loading: 0%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
intro = Image.load("abaddonsparrable/introscreen.png")
screen:print(194, 136, "Loading: 20%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
lvlone = Image.load("abaddonsparrable/levelone intro.png")
screen:print(194, 136, "Loading: 40%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
story = Image.load("abaddonsparrable/story.png")
screen:print(194, 136, "Loading: 60%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
choiceone = Image.load("abaddonsparrable/choice1.png")
screen:print(194, 136, "Loading: 80%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
screen:print(194, 136, "Loading: 100%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
while true do
screen:print(194, 136, "Press START to play", white)
screen.flip()
screen.waitVblankStart()
pad = Controls.read()
if pad:start() then
for a=1,1 do
screen:clear()
screen:blit(0, 0, intro)
screen.flip()
System.sleep(seconds)
end
dofile("something.lua")
end
end
Sorry... :(
Do you Speak German? :)[/code]
- Legacyxero
- Posts: 23
- Joined: Fri Sep 12, 2008 4:42 am
- Legacyxero
- Posts: 23
- Joined: Fri Sep 12, 2008 4:42 am
ok, so i am just saying fuck the "press START to play", its redundant anyway...
but now what i want to do is: after the loading screen ends, i want to load that same picture (Intro) that take up the whole screen. I want that picture to stay on the screen till i press X, then I want it to load ANOTHER picture that takes up the whole screen.
from reading tutorials this is what I have gathered...(my problem's at the end of the code)
My buddy told me that should work, but it just freezes at the 100% screen.
someone please help me.
but now what i want to do is: after the loading screen ends, i want to load that same picture (Intro) that take up the whole screen. I want that picture to stay on the screen till i press X, then I want it to load ANOTHER picture that takes up the whole screen.
from reading tutorials this is what I have gathered...(my problem's at the end of the code)
Code: Select all
pink = Color.new(255, 0 , 153)
blue = Color.new(0 , 153, 255)
orange = Color.new(255, 102, 0)
gray = Color.new(153, 153, 153)
black = Color.new(0 , 0 , 0)
green = Color.new(0, 255, 0)
white = Color.new(225, 225, 225)
--*****LOADING SCREEN*****
screen:print(194, 136, "Loading: 0%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
intro = Image.load("abaddonsparrable/introscreen.png")
screen:print(194, 136, "Loading: 20%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
lvlone = Image.load("abaddonsparrable/levelone intro.png")
screen:print(194, 136, "Loading: 40%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
story = Image.load("abaddonsparrable/story.png")
screen:print(194, 136, "Loading: 60%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
choiceone = Image.load("abaddonsparrable/choice1.png")
screen:print(194, 136, "Loading: 80%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
screen:print(194, 136, "Loading: 100%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
pad = Controls.read()
while true do
screen:blit(0, 0, intro)
if pad:cross() then break end
screen:blit(0, 0, lvlone)
end
My buddy told me that should work, but it just freezes at the 100% screen.
someone please help me.
- Legacyxero
- Posts: 23
- Joined: Fri Sep 12, 2008 4:42 am
OK, ALMOST got it fixed. This is what I got:
It loads the loading screen fine, but when it comes time to display the first image, it displays both images... I guess thats what its doing cause the screen is flashing between the intro and lvlone.
Code: Select all
pink = Color.new(255, 0 , 153)
blue = Color.new(0 , 153, 255)
orange = Color.new(255, 102, 0)
gray = Color.new(153, 153, 153)
black = Color.new(0 , 0 , 0)
green = Color.new(0, 255, 0)
white = Color.new(225, 225, 225)
--*****LOADING SCREEN*****
screen:print(194, 136, "Loading: 0%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
intro = Image.load("abaddonsparrable/introscreen.png")
screen:print(194, 136, "Loading: 20%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
lvlone = Image.load("abaddonsparrable/levelone intro.png")
screen:print(194, 136, "Loading: 40%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
story = Image.load("abaddonsparrable/story.png")
screen:print(194, 136, "Loading: 60%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
choiceone = Image.load("abaddonsparrable/choice1.png")
screen:print(194, 136, "Loading: 80%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
screen:print(194, 136, "Loading: 100%", blue)
screen.flip()
screen.waitVblankStart(60)
screen:clear()
pad = Controls.read()
while true do
screen:blit(0, 0, intro)
screen.flip()
if pad:cross() then break
end
screen:blit(0, 0, lvlone)
screen.flip()
end
It loads the loading screen fine, but when it comes time to display the first image, it displays both images... I guess thats what its doing cause the screen is flashing between the intro and lvlone.