Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / game menu problem

Author
Message
the destroyer
15
Years of Service
User Offline
Joined: 24th Dec 2008
Location:
Posted: 26th Apr 2009 16:49 Edited at: 27th Apr 2009 17:17
Hi, my problem is that when I start te game, i have a menu with play howto and exit buttons, when i press the play button, it starts the game, and when i press escapekey it goes back but when i press play again it shows a message error that says that the sound is already exist
one more problem is that I have a ow quality of the buttons how to make them seem better and how to show huds, is that which way is better, sprites or plains..
hahaha many questions and I hope that somebody could help me
I have attached the whole game with the media
I would like to know what you think about it

Edit:
the atachment seem to not work so i uploaded the game in 4shared
http://www.4shared.com/file/102009742/a624585d/The_yellow_sphere_that_could.html
Neuro Fuzzy
17
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 27th Apr 2009 09:12
i see no attatchment

The first problem is most likely because... well, you've already loaded the sound! when you pressed play the first time, it loaded the sound, but when you pressed escape and went back to the menu, it was still loaded! so when you press play again, you try to load it twice. Try loading the media at the very beginning of your program, or try some other workaround so that the media will only be loaded once.
the destroyer
15
Years of Service
User Offline
Joined: 24th Dec 2008
Location:
Posted: 28th Apr 2009 22:31
I can't come up with a solution... can somebody help me??
Deego
16
Years of Service
User Offline
Joined: 21st May 2008
Location:
Posted: 28th Apr 2009 23:11
Quote: "Try loading the media at the very beginning of your program"


That will do it. Also, when you press escape to reset the game, add "delete sound N", and whatever else in the program that is loaded after the game menu.
feiting shadow
18
Years of Service
User Offline
Joined: 12th Sep 2006
Location:
Posted: 4th May 2009 09:27
is your sound file long?
Usually they close automatically, unless they're still playing...

But in my game, I can load 30+ sounds and have them play at the same time, even duplicated...

Oh, only use Load Sound once, at the beginning of your program. You don't have to worry about unloading it if you do that. (you would in another language). Play Sound is the only function you should call more than once... hope that helps

Signed
------
the destroyer
15
Years of Service
User Offline
Joined: 24th Dec 2008
Location:
Posted: 4th May 2009 15:56
allright thankx for the replies but I have one last request..
Can somebody test my code and try to make a menu that goes to the game after pressing start game and when you are allready in the game and press escapekey then it shows the menu that says..
1ยด=Continue game
2=save
3=load
4=options
5=exit to main menu

thanx and I hope that you understand
pc nerd
User Banned
Posted: 4th May 2009 20:00 Edited at: 4th May 2009 20:01
here is how i go back to my menu, you have to delite everything to be ablle to restart your game. so in the go to menu or GOSUB menu delite all your objects that are in game, also all the music. then you will be able to restart the game fresh.



dweeb

Login to post a reply

Server time is: 2024-11-25 07:38:54
Your offset time is: 2024-11-25 07:38:54