proper particle cleanup in unit destructor; campfire is using new particles now

This commit is contained in:
Titus Tscharntke 2010-02-21 23:30:12 +00:00
parent daa9c94129
commit f80359fdca

View File

@ -154,6 +154,11 @@ Unit::~Unit(){
delete commands.back(); delete commands.back();
commands.pop_back(); commands.pop_back();
} }
// fade(and by this remove) all unit particle systems
while(!unitParticleSystems.empty()){
unitParticleSystems.back()->fade();
unitParticleSystems.pop_back();
}
} }
// ====================================== get ====================================== // ====================================== get ======================================