ctor:function () { this._super(); if ('mouse' in cc.sys.capabilities) cc.eventManager.addListener({ event: cc.EventListener.MOUSE, onMouseDown: function(event){ event.getCurrentTarget().processEvent(event); } }, this); if (cc.sys.capabilities.hasOwnProperty('touches')){ cc.eventManager.addListener({ event: cc.EventListener.TOUCH_ALL_AT_ONCE, onTouchBegan:function (touches, event) { event.getCurrentTarget().processEvent(touches[0]); } }, this); } return true; }, processEvent:function (event) { cc.director.runScene(new MainScene()); }