All,
4-22-14 updated zip file:
- menu can now be placed on edges, not just corners
- add ability to set background image on tabs to none and use wade draw function instead
- add ability to slide main menu into place, very basic.
- uploaded tabMenuJsonDocumentation.pdf to describe json file data
cheers
I put together a little demo of a tab menu for a wade game.
The menu is data driven from a json file
As it is currently written, the menu will only work in one of the four corners of the game screen (top,bottom) (left,right).
Run this demo with the console open to see the messages on menu item clicks.
The main stuff is in menuData.json, tabMenu.js and tabKey.js
The rest of the isometric stuff is just to show what it would look like to interact with a game.
I am not a javascript expert, so I'm sure there are optimizations I have missed.
Specifically, I am using eval() in two instances in the code. I have read that this is a bad practice.
If anyone can suggest replacements for how they are used in the code, I would appreciate it.
This uses the wade 1.1.3 engine and the 1.1.1 iso plugin
In the html, these are loaded from a common directory.
You will have to modify the html file to point to wherever you are getting the wade engine and iso plugin from.
Besides modifying the html, it should run out of the box.
Feel free to reuse the code as you wish. Ignore the copyright stuff at the top of the files
The iso images are all under CC 3.0 so attribution is requested..
cheers