Drawing line from sprite with a touch

Posted by Kaizer on Game Development See other posts from Game Development or by Kaizer
Published on 2013-06-17T06:54:09Z Indexed on 2013/10/18 4:15 UTC
Read the original article Hit count: 138

Filed under:

I am working with cocos2d for the iPhone and I have a question about how to implement the following. I have a circle shaped sprite on my layer. When I touch the sprite and move my finger a line must be drawn from the sprite to where my finger is. When I move my finger on the screen the line must follow (straight line). When I release my finger the line should disappear. In a good looking way I should be able to restyle the line into an arrow.

Can anyone move me in the right direction for this ?

Kind regards

© Game Development or respective owner

Related posts about cocos2d-iphone