mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-13 16:07:45 +00:00
- re-count impact decals each time a savegame is loaded.
This counter is not always reliable, especially when running for longer periods, so putting it in a savegame is not a good idea.
This commit is contained in:
parent
4f0850b098
commit
97e3e858a1
1 changed files with 5 additions and 2 deletions
|
@ -964,7 +964,6 @@ void FLevelLocals::Serialize(FSerializer &arc, bool hubload)
|
||||||
("spotstate", SpotState)
|
("spotstate", SpotState)
|
||||||
("fragglethinker", FraggleScriptThinker)
|
("fragglethinker", FraggleScriptThinker)
|
||||||
("acsthinker", ACSThinker)
|
("acsthinker", ACSThinker)
|
||||||
("impactdecalcount", ImpactDecalCount)
|
|
||||||
("scrolls", Scrolls)
|
("scrolls", Scrolls)
|
||||||
("automap", automap)
|
("automap", automap)
|
||||||
("interpolator", interpolator)
|
("interpolator", interpolator)
|
||||||
|
@ -1015,7 +1014,7 @@ void FLevelLocals::Serialize(FSerializer &arc, bool hubload)
|
||||||
if (arc.isReading())
|
if (arc.isReading())
|
||||||
{
|
{
|
||||||
for (auto &sec : sectors)
|
for (auto &sec : sectors)
|
||||||
{
|
{
|
||||||
P_Recalculate3DFloors(&sec);
|
P_Recalculate3DFloors(&sec);
|
||||||
}
|
}
|
||||||
for (int i = 0; i < MAXPLAYERS; ++i)
|
for (int i = 0; i < MAXPLAYERS; ++i)
|
||||||
|
@ -1029,6 +1028,10 @@ void FLevelLocals::Serialize(FSerializer &arc, bool hubload)
|
||||||
RecreateAllAttachedLights();
|
RecreateAllAttachedLights();
|
||||||
InitPortalGroups(this);
|
InitPortalGroups(this);
|
||||||
|
|
||||||
|
auto it = GetThinkerIterator<DImpactDecal>(NAME_None, STAT_AUTODECAL);
|
||||||
|
ImpactDecalCount = 0;
|
||||||
|
while (it.Next()) ImpactDecalCount++;
|
||||||
|
|
||||||
automap->UpdateShowAllLines();
|
automap->UpdateShowAllLines();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue