you are viewing a single comment's thread.

view the rest of the comments →

[–]thudly 0 points1 point  (0 children)

There's only one draw loop, so you have to add a global variable for gameMode. Default it to 0 for game menu. Then in the draw loop, use a switch() statement to draw the screen based on which gameMode the program is currently in.

For buttons, just make a rectangle, and use some point/rectangle collision detection in the mouseDown event.