Author Topic: Wrong hit order of UIButtons  (Read 3714 times)

fanling3

  • Newbie
  • *
  • Thank You
  • -Given: 4
  • -Receive: 0
  • Posts: 29
    • View Profile
Wrong hit order of UIButtons
« on: July 08, 2014, 08:33:00 PM »
Here is my setup:
UICamera z = -400
UIButton1 inside ScrollView, z = -120, with Box Collider, UIDrag Scroll View, UIPlaySound
UIButton2 z = -220, with Box Collider, UIPlaySound

Culling Mask of UICamera is Everything
Center of Z of all Box Colliders are 0
So according to the depth, UIButton2 should be triggered if UIButton1 and UIButton2 overlap, but the fact is UIButton1 triggered, why would this happen?

Thanks.
« Last Edit: July 08, 2014, 08:59:48 PM by fanling3 »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Wrong hit order of UIButtons
« Reply #1 on: July 09, 2014, 04:03:08 PM »
Z has no effect in NGUI 3. Everything is based on depth.