- Home /
Question by
nicoguerra1337 · Nov 12, 2014 at 02:15 AM ·
buildmousecursorapplication
[SOLVED] Mouse cursor disappears in built application
When I build my application and run it, my mouse cursor is invisible. I have a custom cursor set. I put a script to make it visible but had no luck. Works fine in Unity Editor though. What am I doing wrong?
Here is my script:
using UnityEngine;
using System.Collections;
public class MainMenu : MonoBehaviour {
void Start () {
Screen.showCursor = true;
Screen.lockCursor = false;
}
}
Comment
Best Answer
Answer by nicoguerra1337 · Nov 12, 2014 at 03:15 AM
found the problem, cursor image was not set to Cursor in import settings
Thank you for posting your own answer. Now I have my answer.
Answer by glgamesforfun · Oct 19, 2021 at 03:31 PM
using UnityEngine;
using System.Collections;
public class MainMenu : MonoBehaviour {
void Start () {
Cursor.visible = true;
Screen.lockCursor = false; //old
}
}
Your answer
Follow this Question
Related Questions
Distribute terrain in zones 3 Answers
Mouse won't freeze in center of screen 1 Answer
Screen.lockCursor messes my rotation 1 Answer
How to start Animation left turn With the cursor 1 Answer
Delta event out of Editor Problem 4 Answers