need help with menu

63 views
Skip to first unread message

Soroush Safavi

unread,
Jun 28, 2012, 8:01:51 PM6/28/12
to mel...@googlegroups.com
Hi I am creating a game im almost done i just don't know how can i create a menu at the beginning of the game like high score play and etc. do you have any reference that i can use like a demo?

Thanks

Orthonormal

unread,
Jun 30, 2012, 8:16:27 AM6/30/12
to mel...@googlegroups.com
Yes, there is a reference: http://www.melonjs.org/tutorial/. It is at "Part 9: Adding a title screen". At the end of every section there is an image you can click to go to a working version of the game. Right click and "view source" to grab the source code.

What they did in part 9 is make a title screen at the beginning of the game where you can press "Enter" to start the game. You can modify this so that pressing "Enter" starts the game, pressing "H" goes to the high score screen etc. Then, you should be able to modify this by triggering "Enter" or "H" through mouse clicks. There were some discussions here regarding mouse clicking events.

Hope this helps. Good luck! ^__^
Reply all
Reply to author
Forward
0 new messages