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
1 changed files with 5 additions and 0 deletions

View File

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