Author Topic: drag camera around  (Read 1500 times)

superp

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 14
    • View Profile
drag camera around
« on: June 28, 2014, 04:51:31 PM »
Hi,
I am creating a 2d game and the game screen is bigger than the main camera.
I attached BoxCollider2D to the camera and handle OnDrag in the script attached to the camera.
This works great at moving the screen by dragging on it but whenever i click on the screen it always go to the BoxCollider and the object underneath never gets event.

Is there another way to move the camera by dragging mouse?
Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: drag camera around
« Reply #1 on: June 28, 2014, 05:46:30 PM »
There was an issue with raycasts for 2D box colliders in NGUI 3.6.5 and earlier that was resolved in 3.6.6. Can you try it with the update?