unity5, UI Button "On Button Down"
unity5自带的UI Button的Inspector面板中只有On Click事件,如果我们想让一个按钮响应On Button Down事件该怎么办呢?方法是:
点Add Component->Event->Event Trigger添加一个Event Trigger组件。然后再点Add New Event Type->PointerDown。就得到"On Button Down"事件了。
参考:http://stackoverflow.com/questions/26661212/gui-of-unity-4-6-detecting-on-click-down