Hi,
I've made my drag and drop drop another drag and drop panel and sprite onto the game. Reason is so that I could bring a sprite into the game, and bring it back out again.
Problem is after the drag and drop panel is dropped in the game, when I try to drag it back out again, it gives me this error
NullReferenceException: Object reference not set to an instance of an object
DragDropItem.OnDrag (Vector2 delta) (at Assets/NGUI/Examples/Scripts/Other/DragDropItem.cs:107)
UnityEngine.GameObject:SendMessage(String, Object, SendMessageOptions)
and after that, it auto repositions my ingame panel(probably caused by UITable and the other children GameObject that I put my Colliders in, but I don't know how to fix this).
I've made the conditions of the drag and drop for both ingame and offgame panel/sprite the same, except that the ingame panel is outside the UI Root.
If I put the panel inside the UI Root, the above message doesn't appear, but the panel will continuously reposition itself each time I move it to anywhere in the screen that is not a Drag Drop Surface.
Do you know what I should've done? If you need any other info, please do tell. Thank you!