Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: PabloAM on March 27, 2013, 08:48:35 AM

Title: [SOLVED] Keep Dragging an UIDragObject
Post by: PabloAM on March 27, 2013, 08:48:35 AM
Hello everyone,
I´m having troubles trying to keep dragging an UIDragObject, If I get out from its collider the object stops, But in the example  6 "Draggable Window", you can move the coursor whatever you want and dont stop to move.

What can I do that?

Thanks!
Title: Re: Keep Dragging an UIDragObject
Post by: PabloAM on March 28, 2013, 04:03:35 AM
Hello again, I think this could be fixed activating "Sticky Press" on UICamera, but I can´t found how activate it on run time.

How could I activate it?
Thanks again.

EDITED:
I have done a little hack on NGUI.
To change stickPress on Run time just change the variable stickyPress on UICamera.cs (Line: 116) and add the function as the follow code:
  1. static public bool stickyPress = false;
  2.        
  3.         static public void changeStickTo(bool b)
  4.         {
  5.                 stickyPress = b;
  6.         }
  7.  

You now can change sticky Press with UICamera.changeStickTo(true);

Enjoy it!