Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: stkiller on October 20, 2014, 01:18:10 AM

Title: NGUI with locked/not shown mouse
Post by: stkiller on October 20, 2014, 01:18:10 AM
Hello,

Unity's software mouse doesn't behave well in game - the input is jagged and doesn't allow smooth drag and drop.
I think it would be nicer to have a custom software mouse, based on it's own acceleration and smoothed axis raw input.

The question is - how is it possible to get NGUI controlls to react to a custom cursor, which has position set as described before?
I tried to replace all Input.mousePosition with the value affected by my calculations, but nothing happens.

Could you please help me?
Thank you in advance!
Title: Re: NGUI with locked/not shown mouse
Post by: ArenMook on October 20, 2014, 11:31:05 PM
You would need to create a custom input method (UICamera.onCustomInput). Just feed UICamera.ProcessTouch with the right values. Have a look at UICamera.ProcessFakeTouches function for an example.