In my game I have a city and player, which can walk on the city and come to the houses. When he come to the house I load new scene using Application.LoadLevel. And when he came back to the city I load the previous scene.
The problem is that I want him to stay at that place, where he was, when I loaded scene of the house. But he are at the place, where he was in the start of the game.
I’ve applied script below to the player and object, which contain all scripts:
void Awake()
{
DontDestroyOnLoad(this.transform.gameObject);
}
But now I just have two players instead of one when I load new scene.
How can I make player stay at that place, where he was, when I loaded new scene?