cocos2d subclassing sprite to handle touch?

后端 未结 4 1481
陌清茗
陌清茗 2020-12-18 14:19

I\'m new to the cocos2d(-x) world.

I\'d like to detect a touch to a sprite, and tutorials/examples seem to suggest using layer to detect touch and find the approap

4条回答
  •  执念已碎
    2020-12-18 14:49

    it is better and much more clear to handle touches in one place. but i think, no one can bar you to do this

提交回复
热议问题