|
-
The Cheeze to Your Macaroni
Thanks for the replies. Yea I saw that example from Joa...that was one of the reasons I decided to take that route.
I suppose it would be best to just create multiple pools then...currently my game is structured as follows (the engine anyways) : http:http://www.cheezeworld.com/files/spa...MunsterUML.png
So basically what I could do is have a pool for the same "renderer" object, in which case i'd be using BitmapClipRenderer and all I'd have to do is swap the BitmapClip depending on what "type" of projectile im rendering.
As far as the projectiles I suppose I'll have to create multiple pools for each type of projectile I decide to make...the other solution would to give the "AProjectile" class all the properties than any projectile would need and attach an "actions" class which just has a set of static functions that can be called based on the parameter passed in...( Actions.projectileAction("type", parameters...); )
That would give me a max of 2 pools for the projectiles however it might end up being messy as all of the actions are being stored in one function...and also it would slow things down because I am now calling an extra function withing each projectiles update()...
What do you guys think? Just create multiple pools for multiple types of entities or do the "action" approach?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|