![]() |
| Forums | Gaming News | Videos | Downloads | Today's Posts | Mark Forums Read | Chat | FAQ | Members List | Contact |
| ||||||
This is a discussion on What's wrong with this? within the PSP Development Forum forums, part of the PSP Development, Hacks, and Homebrew category; Code: bsod = Image.load("images/bsod.png") -- Coding while true do pad = Controls.read() if pad:cross() then bsod_image() end -- Functions function ...
![]() |
|
|
LinkBack | Thread Tools |
|
|
#1 |
![]() |
Code:
bsod = Image.load("images/bsod.png")
-- Coding
while true do
pad = Controls.read()
if pad:cross() then
bsod_image()
end
-- Functions
function bsod_image()
screen:blit(0, 0, bsod)
end
|
|
|
|
|
|
#3 |
![]() ![]() Tha Sigerator
|
i think u need to add the function BEFORE the while true do
__________________
- - - - Somewhere Lurking in THA SHADOWS - - - -
|
|
|
|
|
|
#4 |
![]() ![]() Developer
|
yea, so this:
Code:
bsod = Image.load("images/bsod.png")
-- Functions
function bsod_image()
screen:blit(0, 0, bsod)
end
-- Coding
while true do
pad = Controls.read()
if pad:cross() then
bsod_image()
end
|
|
|
|
|
|
#5 |
![]() ![]() Tha Sigerator
|
yea..
__________________
- - - - Somewhere Lurking in THA SHADOWS - - - -
|
|
|
|
|
|
#7 |
![]() |
yaya, thanks xod, i forgot that <.<
Btw, problems with sounds <.< (hole code) Code:
-- Variables
mn_sel = 1 -- Selection
white = Color.new(255, 255, 255)
red = Color.new(255, 50, 0)
bsod = Image.load("images/bsod.png")
monster = Sound.load("sounds/monsterkill.wav",false)
playing = 0
-- Functions
function bsod_image()
screen:blit(0, 0, bsod)
if playing == 0 then
local sound = monster
voice = sound:play()
end
if playing == 1 then
voice:stop()
end
end
-- Coding
while true do
pad = Controls.read()
screen:clear()
playing = 0
if pad:up() then
mn_sel = mn_sel + 1
if mn_sel >= 2 then
mn_sel = 2
end
end
if pad:down() then
mn_sel = mn_sel - 1
if mn_sel < 1 then
mn_sel = 0
end
end
if mn_sel == 1 then
screen:print(180, 130, "-Start Unreal Pwnat0r", red)
screen:print(180, 140, "Exit", white)
if pad:cross() then
bsod_image()
end
end
if mn_sel == 2 then
screen:print(180, 130, "-Start Unreal Pwnat0r", red)
screen:print(180, 140, "Exit", white)
if pad:cross() then
bsod_image()
end
end
if mn_sel == 0 then
screen:print(180, 130, "Start Unreal Pwnat0r", white)
screen:print(180, 140, "-Exit", red)
if pad:cross() then
bsod_image()
end
end
screen:flip()
screen.waitVblankStart()
end
|
|
|
|
|
|
#9 |
![]() ![]() total-Z
|
if playing == 0 then
local sound = monster voice = sound:play() playing = 1 end if playing == 1 then voice:stop() playing = 0 end
__________________
牧来栠摩琠敨映汩獥PSN: youresam From Earth the Frozen Ipaqs shall rise and be silenced and all will live free.
--Mike Hollingsworth |
|
|
|
|
|
#11 |
![]() ![]() total-Z
|
take off the bolded:
while true do pad = Controls.read() screen:clear() playing = 0 that is your problem
__________________
牧来栠摩琠敨映汩獥PSN: youresam From Earth the Frozen Ipaqs shall rise and be silenced and all will live free.
--Mike Hollingsworth |
|
|
|
|
|
#13 |
![]() ![]() total-Z
|
Yeah, I dont know whast wrong, I made the sound only play when it has to, and told it to stop before opening the bsod... oh wait, I think I know. It'll take a bit of code, though. Maybe later.
__________________
牧来栠摩琠敨映汩獥PSN: youresam From Earth the Frozen Ipaqs shall rise and be silenced and all will live free.
--Mike Hollingsworth |
|
|
|
![]() |
| Tags |
| wrong |
| Thread Tools | |
|
|