- Home /
Crosshair and Cursor centering to different positions
Hello,
My cursor has been centered and locked using Screen.lockCursor, and my GUI crosshair has been centered using this code:
//crosshair position and dimensions
crosshairRect = new Rect((Screen.width - crosshairTexture.width)/2, (Screen.height - crosshairTexture.height)/2, crosshairTexture.width, crosshairTexture.height);
When I unlock the cursor to show its position (ie. in the pause menu), the cursor is slightly north of center. This problem is noticeable ingame as you must hover over objects to highlight them.
Does anybody know why this might be happening?
Note: This happens both in the editor and in the build.
Comment
Your answer
Follow this Question
Related Questions
use crosshair as cusor (for clicking and dragging) 2 Answers
how to lock a cursor 1 Answer
2D platformer cursor 1 Answer
first person crosshair 3 Answers
Need to lock the mouse but not in middle - OCULUS RIFT 1 Answer