Skip to content

Main Menu

Philipp Borucki edited this page May 11, 2016 · 6 revisions

The main menu of this game is the first contact point for the player. This menu was designed to get easily edited.


Demonstration: Image of the Menu


The MainMenuManagment.cs contains several structs, methods etc. for simplifying adding functions. In the inspector you can add e.g. new tabs to the Menu with drag and drop.

####Adding tabs To add an menu tab, you need just 2 things [Optional an AudioClip]. A button which is reliable for activating the tab. And a panel, who represents the content of your tab (so the tab is a panel).

Please make sure that your panel has the tag "UITab" for central deactivation purposes. If you have finished your tab. You have to deactivate the panel-gameobject in the inspector.

Now go to the MainMenu game object (where the MainMenuManagment.cs is attached to) and add 1 to the count of the "All Menu Tabs" array. You can now easy add the button and your panel, and if you like to a sound too. Thats it, with a click on the button, the panel should be visible.

#####Add functionality You are now free to add function for your tab, in the MainMenuManagment.cs or somewhere else.

Game functionality

UI
Clone this wiki locally