title: Class Ambiguity Error(ambigious conversion from drived class) With CCStandredTouchDelegate in cocos2dx?
body: <p>I am Subclassing a CCSprite, in order to make Rotation Gesture for a sprite object.</p>
  
  <p>For this purpose i need to use CCTargetedTouchDelegate and CCStandardTouchDelegate
  But even after declaring functions of those delegates i am getting an ambiguity error.</p>
  
  <p><strong>The Error Screen Shot :-</strong></p>
  
  <p><img src="https://i.stack.imgur.com/dVsXU.png" alt="enter image description here"></p>
  
  <p><strong>code in my .h file.</strong></p>
  
  <pre><code>namespace mygames
  {
  
  class DragSprite: public cocos2d::CCSprite, public cocos2d::CCTargetedTouchDelegate, public cocos2d::CCStandardTouchDelegate
  {
      public:
          cocos2d::CCSize canvasSize;
          bool init();
          static DragSprite* createWithFile(const char *pszFileName);
          bool isTouchingOnSprite(cocos2d::CCPoint  touch);
  
          virtual bool ccTouchBegan(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent);
          virtual void ccTouchMoved(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent);
          virtual void ccTouchEnded(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent);
  
      virtual void ccTouchesBegan(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent) ;
      virtual void ccTouchesMoved(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent) ;
      virtual void ccTouchesEnded(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent) ;
      virtual void ccTouchesCancelled(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent) ;
  
          float angleBetweenLineInDegrees(cocos2d::CCPoint startLineA,cocos2d::CCPoint endLineA,cocos2d::CCPoint startLineB,cocos2d::CCPoint endLineB);
  
      ~DragSprite();
       CREATE_FUNC(DragSprite);
      private :
          bool isDrag;
          bool isPinch;
          bool canRotate;
          cocos2d::CCPoint whereTouch;
          cocos2d::CCPoint midPoint;
          int touchNumber;
          float lastDistance;
          float distance;
          float lastAngle;
          float angle;
          float cumulatedAngle;
          float spriteAngle;
          float innerRadious;
          float outerRadious;
          cocos2d::CCArray * touches;
          cocos2d::CCTouch *firstTouch;
          cocos2d::CCTouch *secondTouch;
          float touchDistanceLast;
          float touchDistanceNow;
  
  };
  }
  </code></pre>
  
  <p><strong>error related code in my .cpp file</strong></p>
  
  <pre><code>DragSprite* DragSprite::createWithFile(const char *pszFileName)
  {
  DragSprite *pSprite = new DragSprite();
  if (pSprite&amp;&amp;pSprite-&gt;initWithFile(pszFileName))
  {
      cocos2d::CCDirector::sharedDirector()-&gt;getTouchDispatcher()-&gt;addTargetedDelegate(pSprite, 0, true);
      cocos2d::CCDirector::sharedDirector()-&gt;getTouchDispatcher()-&gt;addStandardDelegate(pSprite, 0);
      pSprite-&gt;setAnchorPoint(ccp(0.5, 0.5));
  
      pSprite-&gt;autorelease();
      return pSprite;
  }
  CC_SAFE_DELETE(pSprite);
  return NULL;
  }
  
  
  bool DragSprite::ccTouchBegan(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent)
  {
  //some code.....
  
  return false/true;
  }
  
  void DragSprite::ccTouchMoved(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent)
  {
  
  //Some Code....
  
  }
  
  void DragSprite::ccTouchEnded(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent)
  {
  //Some Code....
  }
  
  
  void DragSprite::ccTouchesBegan(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent)
  {
  CCLOG("TSB");
  }
  
  
  void DragSprite::ccTouchesMoved(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent)
  {
  CCLOG("TSM");
  }
  
  
  void DragSprite::ccTouchesEnded(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent)
  {
  CCLOG("TSE");
  }
  
  
  void DragSprite::ccTouchesCancelled(cocos2d::CCSet *pTouches, cocos2d::CCEvent *pEvent)
  {
  CCLOG("TSC");
  }
  </code></pre>