How do i enable / disable ccTouchMoved events

Hey
i have CCSprite that received ccTouchMoved event and can be dragged all over the screen
now i want to enable the user to:

  1. move it for 5 or 10 pixels with the ccTouchMoved
  2. the ccTouchMoved event will be disabled that means the user couldn’t drag it
  3. the animation to X or Y direction depending the drag direction will continue another 100 pixels with CCMoveBy action
  4. when animation done enable the ccTouch events

the most important for me is how to enable / disable the ccTouch events
p.s
this is not give me the code question , i just need to know what are the command to use
thanks

I imagine you can call setTouchEnabled and give it false once you’re ready to stop allowing them to move. Or you can maintain this with your own state variables.

well i ended up using state varibale , not sure is this is the best way . (is it ??)
im not using setTouchEnabled , im using CCNode Subclass with CCTargetedTouchDelegate