How to let the CCSprite handles Touch event?
Posted
by Tattat
on Stack Overflow
See other posts from Stack Overflow
or by Tattat
Published on 2010-04-25T05:31:20Z
Indexed on
2010/04/25
5:33 UTC
Read the original article
Hit count: 563
I created my OwnCCSprite, and it get the implemented CCStandardTouchDelegate protocol, and ccTouchesBegan event. But it seems not working. When I click the CCSprite, the ccTouchesBegan in the CCLayer is called, but the CCSprite's ccTouchesBegan can't called. How can I detect the CCSprite is being touched in CCLayer / OwnCCSprite? or I need to calculate the touch position, and compares it to the OwnCCSprite positions?
Thz.....
© Stack Overflow or respective owner