Added OnLoad virtual
Allows for things to be reinitialized where needed for Thinkers. Moved hidden state of items over to OnLoad.
This commit is contained in:
parent
44c9140aad
commit
524cd55813
5 changed files with 24 additions and 3 deletions
|
|
@ -415,12 +415,12 @@ void FThinkerCollection::SerializeThinkers(FSerializer &arc, bool hubLoad)
|
|||
else if (thinker->ObjectFlags & OF_JustSpawned)
|
||||
{
|
||||
FreshThinkers[i].AddTail(thinker);
|
||||
thinker->PostSerialize();
|
||||
thinker->CallPostSerialize();
|
||||
}
|
||||
else
|
||||
{
|
||||
Thinkers[i].AddTail(thinker);
|
||||
thinker->PostSerialize();
|
||||
thinker->CallPostSerialize();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -833,6 +833,16 @@ void DThinker::PostSerialize()
|
|||
{
|
||||
}
|
||||
|
||||
void DThinker::CallPostSerialize()
|
||||
{
|
||||
PostSerialize();
|
||||
IFOVERRIDENVIRTUALPTRNAME(this, NAME_Thinker, OnLoad)
|
||||
{
|
||||
VMValue params[] = { this };
|
||||
VMCall(func, params, 1, nullptr, 0);
|
||||
}
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue