- Home /
Black square cursor
I have a problem with build. I Play on Unity no problem but when I build it it seem black square like this
but my cursor is
is your cursor image uploaded correctly to this post? it's not showing the image for me
Answer by Jessespike · Dec 17, 2015 at 06:42 PM
Quoting Eric5h5:
Try setting the texture type to Cursor, and limiting the size to 32x32. I found that while setting the cursor in the player settings worked in the editor, it did not show up in a build. I worked around that by using Cursor.SetCursor in a script instead.
Didn't work for me. In all windows builds any attempts to set a cursor end up in a black square. I set the image properites to "Cursor", limited its size by 32, set it in a script and in Player Settings - it's still a goddamn black cursor. Just like the default program icon I can't change as well.
Answer by AlienPentiumX · Oct 16, 2017 at 10:12 AM
Go to project window and search your image. Click on it and go to inspector. Then, change texture type to cursor and click apply!
Answer by codemaker2015 · Jul 01, 2021 at 12:11 PM
[SerializeField] Texture2D cursor;
void Start() {
Cursor.SetCursor(cursor, Vector3.zero, CursorMode.ForceSoftware);
}
I found that the Read/Write flags also needed to be set or the cursor just looked like a black square with some random dots on it.
Your answer
![](https://koobas.hobune.stream/wayback/20220612053005im_/https://answers.unity.com/themes/thub/images/avi.jpg)