diff --git a/Source/Engine/Content/Content.cpp b/Source/Engine/Content/Content.cpp index 6d2e52b85..21a96edc1 100644 --- a/Source/Engine/Content/Content.cpp +++ b/Source/Engine/Content/Content.cpp @@ -166,6 +166,9 @@ void ContentService::Dispose() // Save assets registry before engine closing Cache.Save(); + // Flush objects (some asset-related objects/references may be pending to delete) + ObjectsRemovalService::Flush(); + // Unload all remaining assets { ScopeLock lock(AssetsLocker); diff --git a/Source/Engine/Level/SceneObject.h b/Source/Engine/Level/SceneObject.h index d044fe8cc..db58a71b8 100644 --- a/Source/Engine/Level/SceneObject.h +++ b/Source/Engine/Level/SceneObject.h @@ -97,7 +97,7 @@ public: /// /// Determines whether object is during play (spawned/loaded and fully initialized). /// - FORCE_INLINE bool IsDuringPlay() const + API_PROPERTY() FORCE_INLINE bool IsDuringPlay() const { return (Flags & ObjectFlags::IsDuringPlay) != 0; }