- Home /
save game menu
Hello
I would like to save the progress of my game. I created a cube in the menu, I click that link to save your progress. How do I do?
I have a script.
function Update () {
if (Input.GetMouseUp (0))
Application.Savelevel (3);
}
This script I have assigned to the cube (is trigger) but it does not work the rescue. Can anyone help me? Thank you.
Answer by whydoidoit · Oct 06, 2012 at 05:09 PM
You have to use a plug in to save the progress of a level or write the code yourself and put the information in a file or in PlayerPrefs. Plugins make it simpler, but it is never easy as you need to worry about all of the stuff that needs to be saved; scripting it yourself can be tricky if your levels are not simple.
I provide a free plugin called Unity Serializer.
Thanks for your help.
the script you suggested, where do I assign it? $$anonymous$$enu to save your progress? In the scenes of the game?
You would have to follow the Getting Started Guide that tries to help identify everything that needs doing. Then you would use Pause$$anonymous$$enu.js or TestSerialization.cs as starting points for a save game system.
Answer by Tomperke · Mar 22, 2014 at 05:18 PM
I used Unity Serializer AND i get the pause menu, but there is no mouse support in there to click the save button. Any idea how i can resolve this?