- restored ZDoom 2.8.1's version of FindClassTentative which just modified the existing class instead of replacing it and having to run a costly and volatile PointerSubstitution call to replace all pointers to the old one.

This commit is contained in:
Christoph Oelckers 2017-02-08 19:52:33 +01:00
commit 9499c22dfe
2 changed files with 18 additions and 43 deletions

View file

@ -396,8 +396,9 @@ void LoadActors()
{
Printf(TEXTCOLOR_ORANGE "Class %s referenced but not defined\n", ti->TypeName.GetChars());
FScriptPosition::WarnCounter++;
DObject::StaticPointerSubstitution(ti, nullptr);
PClassActor::AllActorClasses.Delete(i);
// the class must be rendered harmless so that it won't cause problems.
ti->ParentClass = RUNTIME_CLASS(AActor);
ti->Size = sizeof(AActor);
}
else
{