Beispiel #1
0
        void onTouchesBegan(List <CCTouch> touches, CCEvent touchEvent)
        {
            foreach (var item in touches)
            {
                CCTouch    touch      = (item);
                TouchPoint touchPoint = TouchPoint.TouchPointWithParent(this);
                CCPoint    location   = touch.Location;
                touchPoint.SetTouchPos(location);
                touchPoint.SetTouchColor(s_TouchColors[touch.Id % 5]);

                AddChild(touchPoint);
                s_dic.Add(touch.Id, touchPoint);
            }
        }
Beispiel #2
0
        public override void TouchesBegan(List <CCTouch> touches)
        {
            foreach (var item in touches)
            {
                CCTouch    touch      = (item);
                TouchPoint touchPoint = TouchPoint.TouchPointWithParent(this);
                CCPoint    location   = touch.Location;

                touchPoint.SetTouchPos(location);
                touchPoint.SetTouchColor(s_TouchColors[touch.Id % s_TouchColors.Length]);

                AddChild(touchPoint);
                s_dic.Add(touch.Id, touchPoint);
            }
        }