- Home /
How do I reload a scene with the character in a certain position?
Hello,
I'm making an old school rpg and I'm having an issue with my character when I enter the castle then come back out. When I exit the castle I need to have the character standing right outside the castle, but he automatically goes back to the original starting point of the game, and there is a clone of him there.
A bit of other info. I'm starting on the World Map with a town and castle nearby. I have a DontDestroyOnLoad thing in the script for the hero and the main camera. I think thats where my cloning problem is coming from... but I think my real problem is that I'm just going about it all wrong.
Is there a simple(r) way to do what I'm trying to do? Classic rpg go into town and come back out type of stuff.
Answer by Proportion · Oct 16, 2011 at 06:43 AM
ya, you need to turn your character into a prefab. then take him out of your game. and instead of starting yer level with him in there, use instansiate once you do that you should be able to make like a game logic script saying what building your character was last in. or even an array of spawning locations to your character, and if he goes through the exit trigger of one area, he can appear at gamelocation 2 or something.
Thanx! Didn't even think of those things. Instantiate and spawn points. Right on.
np, word me up when your game is up somewhere so i can have a play :D
Your answer
![](https://koobas.hobune.stream/wayback/20220613011737im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Loading new level after killing enemies 3 Answers
Inventory code not working [JS] 0 Answers
Anyway to complete this action? 0 Answers