How do you create a main menu?
Hello, I am currently working on my first game, as far as the look of the menu goes I already have it set up the way I want it for now however, none of the buttons work. I have a New Game, Load Game, and an Exit Game button and im wondering what the scripts look like for those to work as I do not know C#. I do plan on learning it as I go so that way ill be able to do things on my own later but for now I would love some much needed help. So my next Question is going to be how to make a pause menu and an inventory for the character. Thanks.
Answer by ItzChris92 · Aug 04, 2017 at 07:12 PM
I imagine you are using buttons? If so then you can use the OnClickEvent on the button to run a method that will load a particular scene.
https://docs.unity3d.com/ScriptReference/SceneManagement.SceneManager.LoadScene.html
Write a script similar to the one in the docs that loads a scene and attach it to your button. Drag the button gameobject into the event and select the function.
Before attempting something as complex as an inventory system using C# I really recommend learning the basics and then attempt something more difficult. There are loads of tutorials on how to do so (youtube is very good). I've only been learning C# for 6 months and have just finished writing my own inventory system. You won't get far without learning the fundamentals. Good luck!
Your answer
Follow this Question
Related Questions
How do you make your player jump in the Roll-a-Ball tutorial series? 0 Answers
How do I inactivate Text in a script? 2 Answers
please help me, i'm creating a first person game, but my script is incomplete and i can't crouch 0 Answers
Drag and drop a plane coping terrain 0 Answers
How to make a thrown object land on a certain point e.g a thrown spear landing on its tip 0 Answers