x


Remember the States of the Last Game Scene

Hello,

I am pretty new with Unity. I have a general question regarding game scenes. Suppose a game consists of several scenes. Let us say that a player was exploring one of the scenes and made some changes to the scene (e.g. objects are moved). Let us say that the player stopped playing and exit the game at one point. In order for the player to return to the same scene with exactly the same states as when he exited, I guess we need to record the states information somewhere. If it is deplored through the web, I guess the information has to be stored in a database.

I would appreciate any information and help in this regard.

Thank you, Wei Jin

more ▼

asked Nov 19 '11 at 08:35 PM

wjin gravatar image

wjin
1 1 1

(comments are locked)
10|3000 characters needed characters left

1 answer: sort voted first

This is not a simple task. They way I usually approach this is to create my own load/save handler.

It usually operates by looping through everything that I want to be persistent, and saving specific data in the PlayerPrefs. Then the handler has to go through what was saved when its time to load, and apply that data to those things I want to be persistent.

PlayerPrefs is stored locally so there would be no need for a server/database.

I'm not familiar with any quick solutions for this. Not even in Unity.

more ▼

answered Nov 21 '11 at 03:55 PM

DoktorAce gravatar image

DoktorAce
106 4 4 7

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x232
x17

asked: Nov 19 '11 at 08:35 PM

Seen: 360 times

Last Updated: Nov 21 '11 at 03:55 PM