Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: zippo227 on July 03, 2015, 10:26:44 AM

Title: Why does UICamera hide the mouse cursor?
Post by: zippo227 on July 03, 2015, 10:26:44 AM
Why is there code in UICamera that arbritrarily turns on and off the mouse cursor? This resets the cursor position and makes it so that my player character cannot walk and move the mouse cursor at the same time. I've had to comment out the Cursor.visible = true and Cursor.visible = false lines in UICamera to get my game working again.
Title: Re: Why does UICamera hide the mouse cursor?
Post by: ArenMook on July 03, 2015, 11:46:04 AM
Happens when you get joystick input. You may have WASD bound to joystick axes by default, with same axes specified on UICamera.
Title: Re: Why does UICamera hide the mouse cursor?
Post by: devomage on July 03, 2015, 02:50:54 PM
Why is there code in UICamera that arbritrarily turns on and off the mouse cursor? This resets the cursor position and makes it so that my player character cannot walk and move the mouse cursor at the same time. I've had to comment out the Cursor.visible = true and Cursor.visible = false lines in UICamera to get my game working again.

this recently became a huge problem for me as well.  the cursor snaps to the center of the screen.  is there a way to toggle this behavior?  i've yet to look into it, but is very annoying.

edit:

commenting out line #: 492, 493 and 506, 507

fixed the problem for me...
Title: Re: Why does UICamera hide the mouse cursor?
Post by: zippo227 on July 08, 2015, 09:55:58 AM
I commented out the same lines relating Cursor.lockState and Cursor.visble. Yes my Navigation X and Navigation Y are set to Horizontal and Vertical respectively, and my Horizontal and Vertical take joystick input. I can kind of see why you would want to have special joystick configurations, but it seems to me that the default should treat the joystick like a mouse.