Hi,
I'm trying to create a highlighting effect on a CCSprite, where if you click on the sprite, a coloured border surrounds it.
Creating separate images for the highlighted and non-highlighted versions is out of the question because I have too many sprite images, and doubling in image size is not good.
So far, I have tried creating a duplicate CCSprite from the same image (to get its shape), and subsequently calling setColor on the sprite to fill it with a solid colour. My plan was to increase this duplicate sprite's size by, say, 10%, and overlay the original sprite on top of it to give it the highlight feel. However, setting the sprite colour to, for example, red, makes it look "more red" as opposed to a full solid red colour. Even if this idea works, I'm not convinced that this is the best solution.
If somebody could offer any suggestions on how to properly do this kind of highlighting effect on CCSprite's, I would be very grateful. Or if you have any ideas on how to properly set the colour of a sprite, I would appreciate that as well.
Thanks,
Terry