Standard Assets First Person Controller hiding cursor after changing scenes
I have a first person shooter set up with the standard assets FPSController in one scene, and a menu set up in another scene. Upon changing from the FPS to the menu, the cursor is still hidden. I've tried Cursor.visible = true both before and after changing scenes, and it's still hidden. I also can't use Escape to show the cursor after switching the scene. Any ideas as to what I'm doing wrong?
Thanks in advance.
Answer by egwillfriedel · Sep 27, 2016 at 11:01 PM
When your new scene opens use this:
void Start(){
Cursor.visible = true;
Screen.lockCursor = false;
}
hope this helps!
I know this is old but I have the same problem, where exactly in the code would I put this?
Thank you so much, I was stuck here for ages Also if anyone wondering where to put this code, I just put this code where I was calling the SceneManager.LoadScene(0). Hope it helps
Your answer
Follow this Question
Related Questions
Mouse position is offset from where it should be based on actual mouse position from origin. 1 Answer
UI Toggles not working on start scene 0 Answers
Mouse Cursor Problem 0 Answers
UI text wont highlight 0 Answers
How can I stop custom mouse cursor from reverting back to standard cursor when new Scene loads? 2 Answers