Hey guys,
I've been using Cocos2D for a while now, plodding along doing things in my own way. I'm coming to the point now where I want to make better games and want to make sure the methods I use are the correct etc.
First of all bullets. If I have say a side scrolling shooter game where the player controls a ship that can shoot bullets, the way I have done this in the past is created 10 bullet sprites when the layer starts and just keep repositioning them everytime they go off screen, putting them in a queue ready to be fired again. Is this the most memory efficient way of doing things or should I be creating a new sprite each time and kill it afterwards? If so how would I do that?
Secondly, I'm just getting to grips with using AtlasSprites. One concern I am having with them is knowing when to create them. With sprites in the past I have initialized them in the header file and allocated them when the layer starts, this is because there are a few different functions that will use the sprite, such my collision detections etc. Is it OK to do this with AtlasSprites or should I be doing something different.
Thanks a lot guys, the forums have been a huge huge help with my game dev, so thanks.
Moakesy