• Advertisement
Sign in to follow this  

Menus, game states confusion.

This topic is 3708 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I was wondering what the general thing to do is with menus. I've completed my basic game engine, made a few levels. Now I want to make a menu. How would you do this? Is it worth making a gui class that's really simple, or use an existing one? How should I decide what to draw/process? Using a state variable? Thanks!

Share this post


Link to post
Share on other sites
Advertisement
You can use the state design pattern. Here's a short article about it.

Regarding the actual rendering of the menu, I guess it depends on what you want. Do you want to program a GUI for this, or do you prefer to spend you time on other things? For many people it's the latter, in which case they just use an existing library. It will save you time and the library will be more robust and feature rich than the (probably simple and limited) solution you'll come up with.

Share this post


Link to post
Share on other sites
I haven't used freeglut but if it hold true to its glut roots it offers right click menus out of the box.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement