How to do a game menu?

Game Editor comments and discussion.

How to do a game menu?

Postby futuro » Mon Apr 13, 2009 1:54 pm

Hello to everyboby,

I'm soooooooo new in this and y want know how do a global menu for all the game, in every time when you player and pres one buton (start for gp2x) pause game an show the menu...

Is possible?

How?

Sorry, my english language its so awful, Can you speak soooooooooooooo lowly?
thanks guys
alguien que hable mi idioma ÑñÑñÑñ
User avatar
futuro
 
Posts: 37
Joined: Mon Apr 13, 2009 1:22 pm
Score: 0 Give a positive score

Re: How to do a game menu?

Postby DST » Mon Apr 13, 2009 8:19 pm

PauseGameOn();
PauseGameOff();

You can still recieve mouse/keyboard events during this time. You can't really animate the menus, but you can have buttons that can be clicked on.

So create an actor called menu or something. Make all menu parts children of this actor.
Put this menu and all of its parts above or below the action screen.
Make a pause variable to simplify the control of all of this.

give it a 50% transparent black screen cover....and overlay pause menu options on that(the smokeout effect of this over the action when paused is a really nice effect).

Always create one menu actor, and have all other menu pieces as children of that, so you can control the whole menu easily.

So for instance, actorx>keydown>start>
Code: Select all
switch(pausevariable){
case 0:
menu.y=n; //Where n puts the menu onscreen
pausevariable=1;
PauseGameOn();
break;
case 1:
PauseGameOff();
pausevariable=0;
meny.y=m; //where m puts the menu offscreen again
break;
}
It's easier to be clever than it is to be kind.
http://www.lostsynapse.com
http://www.dstgames.com
User avatar
DST
 
Posts: 1117
Joined: Sun Apr 15, 2007 5:36 pm
Location: 20 minutes into the future
Score: 151 Give a positive score

Re: How to do a game menu?

Postby futuro » Tue Apr 14, 2009 4:52 pm

ok, I this code from one actor is for all the game alwais the pause on
Ok?

thanks you



"Minipoint for you" (joke)
alguien que hable mi idioma ÑñÑñÑñ
User avatar
futuro
 
Posts: 37
Joined: Mon Apr 13, 2009 1:22 pm
Score: 0 Give a positive score

Re: How to do a game menu?

Postby MrJolteon » Sat Apr 18, 2009 2:09 pm

DST wrote:switch(pausevariable){
case 0:
menu.y=n; //Where n puts the menu onscreen
pausevariable=1;
PauseGameOn();
break;
case 1:
PauseGameOff();
pausevariable=0;
meny.y=m; //where m puts the menu offscreen again
break;
}

There's a wrong spelled word.
It's the red word.
Join us on Discord!
Game Editor 2
These are the best ways to reach me these days


Your local Community Janitor, always lurking in the shadows...
User avatar
MrJolteon
 
Posts: 2326
Joined: Sat Aug 09, 2008 3:25 pm
Location: Stranded under endless sky
Score: 105 Give a positive score

Re: How to do a game menu?

Postby futuro » Sat Apr 18, 2009 2:15 pm

maybe change into a 'menu.y'
alguien que hable mi idioma ÑñÑñÑñ
User avatar
futuro
 
Posts: 37
Joined: Mon Apr 13, 2009 1:22 pm
Score: 0 Give a positive score

Re: How to do a game menu?

Postby MrJolteon » Sat Apr 18, 2009 2:16 pm

I didn't understand how to use that code...
Join us on Discord!
Game Editor 2
These are the best ways to reach me these days


Your local Community Janitor, always lurking in the shadows...
User avatar
MrJolteon
 
Posts: 2326
Joined: Sat Aug 09, 2008 3:25 pm
Location: Stranded under endless sky
Score: 105 Give a positive score

Re: How to do a game menu?

Postby Kalladdolf » Sun Apr 19, 2009 11:44 am

Could you tell us what part you didn't understand? Or are you not familiar with the expressions?
User avatar
Kalladdolf
 
Posts: 2427
Joined: Sat Sep 08, 2007 8:22 am
Location: Germany
Score: 120 Give a positive score


Return to GE - General

Who is online

Users browsing this forum: No registered users and 1 guest

cron