android
  #1  
Old 02-17-2010, 05:41 PM
cmalcolm23 cmalcolm23 is offline
Junior Member
 
Join Date: Feb 2010
Location: Scotland :D
Posts: 21
Default pacman soundboard - ZENPacman

hey, here is my first go at an app for the zen. I hav NEVER done any programming before in my life so it may not be the best but i am happy with it :P. its a copy of the zendaft app but with pacman sounds. i hope everyone likes it and all feedback/improvements are welcome.
the layout is the same as on zendaft as i don't know how to do anything different.

it's large so i had to put it on mediafire:

http://www.mediafire.com/?zk2mmwuwdhg

enjoy!!
Reply With Quote

Advertisement [Remove Advertisement]

  #2  
Old 02-19-2010, 03:14 PM
Free Radical Free Radical is offline
Junior Member
 
Join Date: Feb 2010
Posts: 2
Default

Nice, pretty cool for a first try at programming
Reply With Quote

  #3  
Old 02-19-2010, 03:15 PM
cmalcolm23 cmalcolm23 is offline
Junior Member
 
Join Date: Feb 2010
Location: Scotland :D
Posts: 21
Default

thanks, i thought so!! =P
Reply With Quote

  #4  
Old 02-19-2010, 03:24 PM
RobertsAccount's Avatar
RobertsAccount RobertsAccount is offline
X-Fi2 App Master
 
Join Date: Jan 2010
Location: UK
Posts: 310
Default

Fantastic for a first app! It just blows my first and only app out of the water
Reply With Quote

  #5  
Old 02-19-2010, 03:36 PM
cmalcolm23 cmalcolm23 is offline
Junior Member
 
Join Date: Feb 2010
Location: Scotland :D
Posts: 21
Default

aww thanks but not really. besides, i can't really take the credit for it, all i did was change a few things. the real pro is jesspur
Reply With Quote

  #6  
Old 02-19-2010, 03:52 PM
Habhome's Avatar
Habhome Habhome is offline
Moderator
 
Join Date: Jan 2010
Location: Sweden
Posts: 1,079
Default

Nice adaption of the ZENdaft code. But it still contains the same error as the original: When you press home an error occurs and the app crashes.

I know you're not a programmer and can't fix it, and neither have the others who has used it seemed to been able to either. I looked into yours and noticed what was wrong with your code. I attached the fixed MAIN.LUA in a zip.

The problem was with these pieces of code:

Code:
        -- Load images
	   imgBg = image.load("background.png");
	   -- Load sounds
	   ambient_arcade = wav.load("sounds/ambient_arcade.wav")
	   chomp = wav.load("sounds/chomp.wav")
	   chomping = wav.load("sounds/chomping.wav")
	   death_ms = wav.load("sounds/death_ms.wav")
	   eat_fruit = wav.load("sounds/eat_fruit.wav")
	   eat_ghost = wav.load("sounds/eat_ghost.wav")
	   eating_cherry = wav.load("sounds/eating_cherry.wav")
	   eating_ghosts = wav.load("sounds/eating_ghosts.wav")
	   extra_life = wav.load("sounds/extra_life.wav")
	   insert_coin = wav.load("sounds/insert_coin.wav")
	   intermission = wav.load("sounds/intermission.wav")
	   pacman_dies = wav.load("sounds/pacman_dies.wav")
	   pacman_fever = wav.load("sounds/pacman_fever.wav")
	   siren = wav.load("sounds/siren.wav")
	   start_game = wav.load("sounds/start_game.wav")
	   start_of_game = wav.load("sounds/start_of_game.wav")
	   stop = wav.load("stop.wav")
There is no stop.wav audio file, so you can't load it.

Code:
elseif (control.isButton()==1) and (button.click() == 1) then	
					stop:play()
					stop:close()
					break
			end
If there is no stop you can neither play it nor close it.

The red parts of the code should be removed.
and this part should be added at the very end to close all loaded audio files.

Code:
start_of_game:close()
start_game:close()
siren:close()
pacman_fever:close()
pacman_dies:close()
intermission:close()
insert_coin:close()
imgBg:close()
ambient_arcade:close()
chomp:close()
chomping:close()
death_ms:close()
eat_fruit:close()
eat_ghost:close()
eating_cherry:close()
eating_ghosts:close()
extra_life:close()
This can be implemented in all soundboard apps based on the ZENdaft, but you have to exchange the names for your files of course.

Hope this helped and solved your error, it will be easier to see what I did if you just look in the MAIN.LUA I attached.
Attached Files
File Type: zip MAIN.zip (848 Bytes, 41 views)
__________________
"If you are good enough at English to apologize, then there is no need to." - A good friend of mine
Discovered something about the X-Fi2 you think others may not know? Post it here so others can learn about it!
Have a question about X-Fi2 apps? Consult the FAQ before creating a thread about it.
Like my work? Tell your friends. Don't like it? Tell me so I can improve. ^.^

Last edited by Habhome; 02-19-2010 at 04:03 PM.
Reply With Quote

  #7  
Old 02-19-2010, 04:14 PM
cmalcolm23 cmalcolm23 is offline
Junior Member
 
Join Date: Feb 2010
Location: Scotland :D
Posts: 21
Default

thats great thanks but i already fixed the problem. i ran the app on the simulator and realised that that was where the error was coming from so i just deleted the command for stop.wav and it seems to be working fine. thanks for the help
Reply With Quote

  #8  
Old 02-19-2010, 04:30 PM
Habhome's Avatar
Habhome Habhome is offline
Moderator
 
Join Date: Jan 2010
Location: Sweden
Posts: 1,079
Default

Quote:
Originally Posted by cmalcolm23 View Post
thats great thanks but i already fixed the problem. i ran the app on the simulator and realised that that was where the error was coming from so i just deleted the command for stop.wav and it seems to be working fine. thanks for the help
That's nice that you managed to fix ^^
But I still think you should have the closes at the end, I think it is better for the player.
__________________
"If you are good enough at English to apologize, then there is no need to." - A good friend of mine
Discovered something about the X-Fi2 you think others may not know? Post it here so others can learn about it!
Have a question about X-Fi2 apps? Consult the FAQ before creating a thread about it.
Like my work? Tell your friends. Don't like it? Tell me so I can improve. ^.^
Reply With Quote

  #9  
Old 02-19-2010, 05:14 PM
cmalcolm23 cmalcolm23 is offline
Junior Member
 
Join Date: Feb 2010
Location: Scotland :D
Posts: 21
Default

yeah thanks, i added them on to the end. i also have a question... i hav added in a new splash.lua file and it works fine. it uses orange and red text and a sound file and all work properly. when this is attached however, the writing on the main program page is now orange instead of the yellow it was. i have tried to fix it but i cant get it back to yellow. it even turned to black at one point even thought there is no black in the script. can you try and help me please?
Reply With Quote

  #10  
Old 02-19-2010, 05:19 PM
Habhome's Avatar
Habhome Habhome is offline
Moderator
 
Join Date: Jan 2010
Location: Sweden
Posts: 1,079
Default

Quote:
Originally Posted by cmalcolm23 View Post
yeah thanks, i added them on to the end. i also have a question... i hav added in a new splash.lua file and it works fine. it uses orange and red text and a sound file and all work properly. when this is attached however, the writing on the main program page is now orange instead of the yellow it was. i have tried to fix it but i cant get it back to yellow. it even turned to black at one point even thought there is no black in the script. can you try and help me please?
PM me a link with the buggy version and I will give it a shot tomorrow, unless you've fixed it by then. It's 00:20AM here and I'm headed for bed.
__________________
"If you are good enough at English to apologize, then there is no need to." - A good friend of mine
Discovered something about the X-Fi2 you think others may not know? Post it here so others can learn about it!
Have a question about X-Fi2 apps? Consult the FAQ before creating a thread about it.
Like my work? Tell your friends. Don't like it? Tell me so I can improve. ^.^
Reply With Quote

  #11  
Old 02-25-2010, 03:27 PM
Mr Wunderbar's Avatar
Mr Wunderbar Mr Wunderbar is offline
Junior Member
 
Join Date: Jan 2010
Posts: 93
Default

hi guys, im trying to make my own of this but whenever i use it it either returns to menu with an "error occured!" message or my player crashes. help?
Reply With Quote

  #12  
Old 02-25-2010, 04:00 PM
Habhome's Avatar
Habhome Habhome is offline
Moderator
 
Join Date: Jan 2010
Location: Sweden
Posts: 1,079
Default

Quote:
Originally Posted by Mr Wunderbar View Post
hi guys, im trying to make my own of this but whenever i use it it either returns to menu with an "error occured!" message or my player crashes. help?
Can't really help with that little information. Make a thread about the app and post it as it is so people can look at your code and point out errors.
__________________
"If you are good enough at English to apologize, then there is no need to." - A good friend of mine
Discovered something about the X-Fi2 you think others may not know? Post it here so others can learn about it!
Have a question about X-Fi2 apps? Consult the FAQ before creating a thread about it.
Like my work? Tell your friends. Don't like it? Tell me so I can improve. ^.^
Reply With Quote

  #13  
Old 03-02-2010, 08:18 AM
jespuur jespuur is offline
Junior Member
 
Join Date: Feb 2010
Location: Sweden
Posts: 4
Default

Quote:
Originally Posted by cmalcolm23 View Post
aww thanks but not really. besides, i can't really take the credit for it, all i did was change a few things. the real pro is jesspur
The real pro is Dankarn who wrote all the code. i only fixed the sounds and pictures, and the idea.
Reply With Quote

Reply

Tags
pacman, soundboard

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 01:18 AM.