cocosCreator 滑动屏幕事件(tilemap)

1、初始化(添加监听)

        this.scale = 1;
        this.isDistance = true;
        var listener = {
                            event: cc.EventListener.TOUCH_ALL_AT_ONCE,

                                onTouchesBegan:function(touch,event)     
                                {
                                    if (self.stopTouch) { return true; }
                                    self.TouchJudge = false;
                                    self.onTouchStart(touch,event);
                                    return true;
                                },
                                onTouchesMoved:function(touch,event)
                                {
                                    if (self.stopTouch) { return true; }
                                    self.onTouchMove(touch,event);
                                    return true;
                                },
                                onTouchesEnded:functi

你可能感兴趣的:(cocosCreator,cocosCreator)