Author Topic: Need Help with touch controls  (Read 3103 times)

mihnea2kx

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Need Help with touch controls
« on: January 30, 2015, 06:03:38 AM »
There is a snapshot in the attachment . All the coins have a boxcollider, a button script and a tween position script to move on the screen . I want to drag one coin over another and access both the coins properties . I tried using OnDragStart() , OnPress(bool isPressed) but no luck .
Any help would be appreciated .

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Need Help with touch controls
« Reply #1 on: January 30, 2015, 02:58:27 PM »
Only the top-most object will receive events. This is why when dragging something, NGUI's drag & drop scripts happen to disable the dragged object. This way it doesn't eat up all events and it becomes possible for objects underneath it to receive OnDragOver / OnDragOut.