mirror of
https://github.com/devZoGok/PlanetFleet.git
synced 2026-08-26 19:43:29 +00:00
factored out initFx method
refactored creation of explosion FX
This commit is contained in:
@@ -325,7 +325,10 @@ namespace battleship{
|
||||
displayUnitStats(slot.foreground, slot.background, (int)((bool)slot.vehicle), (int)true, renderSelectables, slot.offset);
|
||||
|
||||
if (health <= DEATH_HP){
|
||||
Environment::explode(pos, 0, 0, deathSfx);
|
||||
FxManager *fxManager = FxManager::getSingleton();
|
||||
FxManager::Fx *deathFx = fxManager->initFx(generateView()[getGameObjTableName()][id + 1]["deathFx"], model, false, pos);
|
||||
deathFx->toggleComponents(true);
|
||||
fxManager->addFx(deathFx);
|
||||
remove = true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user