Refactor scene objects initialization to call OnAwake before all OnStart

#520
This commit is contained in:
Wojtek Figat
2022-07-17 17:05:59 +02:00
parent 9aff782907
commit 3239150a61
14 changed files with 59 additions and 114 deletions

View File

@@ -190,9 +190,7 @@ Actor* PrefabManager::SpawnPrefab(Prefab* prefab, Actor* parent, Dictionary<Guid
{
auto obj = sceneObjects->At(i);
if (obj)
{
obj->PostLoad();
}
obj->Initialize();
}
// Synchronize prefab instances (prefab may have new objects added or some removed so deserialized instances need to synchronize with it)