码迷,mamicode.com
首页 > 其他好文 > 详细

[转]如何处理UI对象和场景对象点击事件冲突/重复

时间:2015-11-19 14:26:47      阅读:104      评论:0      收藏:0      [点我收藏+]

标签:

It‘s kind of annoying how clicks on UI elements interact with the game world right? And the documentation is kind of sketchy on how to fix this.

Here are three sure fire ways to block clicks on UI elements. I recommend watching the whole video, and choosing the one that suits your project best.

Video URL: https://www.youtube.com/watch?v=EVZiv7DLU6E

 

和尚注:

方法一:

EventSystem.current.IsPointerOverGameObject()

方法二:

Event Trigger

方法三:

Event System Interfaces

[转]如何处理UI对象和场景对象点击事件冲突/重复

标签:

原文地址:http://www.cnblogs.com/yaohj/p/4977265.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!