Dynamically create class object?,
Members - Reputation: 454
Posted 16 December 2012 - 11:01 AM
Crossbones+ - Reputation: 33030
Posted 16 December 2012 - 11:25 AM
When you are ready to create a new one, call:
enemies.push_back(MyEnemy(model, animation, position, rotation, scale, etc...);
When drawing or updating enemies, you iterate over the entire vector.
Edited by Servant of the Lord, 16 December 2012 - 11:25 AM.
It's perfectly fine to abbreviate my username to 'Servant' or 'SotL' rather than copy+pasting it all the time.
All glory be to the Man at the right hand... On David's throne the King will reign, and the Government will rest upon His shoulders. All the earth will see the salvation of God.
Of Stranger Flames - [indie turn-based rpg set in a para-historical French colony] | Indie RPG development journal | [Fly with me on Twitter]
Crossbones+ - Reputation: 4498
Posted 16 December 2012 - 12:29 PM
I gets all your texture budgets!