From 4be2f05bb1ae30063117d33d8f1b8e221c190983 Mon Sep 17 00:00:00 2001 From: JeffR Date: Wed, 11 Jun 2025 00:30:36 -0500 Subject: [PATCH] Disables the behavior for building and exporting polyLists for SceneGroups as you can just do so on the individual items, and it can cause erroneous behavior like looping if triggered improperly. --- Engine/source/T3D/SceneGroup.cpp | 43 -------------------------------- Engine/source/T3D/SceneGroup.h | 4 +-- 2 files changed, 2 insertions(+), 45 deletions(-) diff --git a/Engine/source/T3D/SceneGroup.cpp b/Engine/source/T3D/SceneGroup.cpp index c753b446a..ab6d4279f 100644 --- a/Engine/source/T3D/SceneGroup.cpp +++ b/Engine/source/T3D/SceneGroup.cpp @@ -364,51 +364,8 @@ void SceneGroup::unpackUpdate(NetConnection* conn, BitStream* stream) } } -bool SceneGroup::buildPolyList(PolyListContext context, AbstractPolyList* polyList, const Box3F& box, const SphereF& sphere) -{ - Vector foundObjects; - if (empty()) - { - Con::warnf("SceneGroup::buildPolyList() - SceneGroup %s is empty!", getName()); - return false; - } - findObjectByType(foundObjects); - - for (S32 i = 0; i < foundObjects.size(); i++) - { - foundObjects[i]->buildPolyList(context, polyList, box, sphere); - } - - return true; -} - -bool SceneGroup::buildExportPolyList(ColladaUtils::ExportData* exportData, const Box3F& box, const SphereF& sphere) -{ - Vector foundObjects; - findObjectByType(foundObjects); - - for (S32 i = 0; i < foundObjects.size(); i++) - { - foundObjects[i]->buildExportPolyList(exportData, box, sphere); - } - - return true; -} - void SceneGroup::getUtilizedAssets(Vector* usedAssetsList) { - //if (empty()) - return; - - Vector foundObjects; - findObjectByType(foundObjects); - - for (S32 i = 0; i < foundObjects.size(); i++) - { - SceneObject* child = foundObjects[i]; - - child->getUtilizedAssets(usedAssetsList); - } } DefineEngineMethod(SceneGroup, recalculateBounds, void, (), , diff --git a/Engine/source/T3D/SceneGroup.h b/Engine/source/T3D/SceneGroup.h index f9e4afeaa..66ecfff77 100644 --- a/Engine/source/T3D/SceneGroup.h +++ b/Engine/source/T3D/SceneGroup.h @@ -49,8 +49,8 @@ public: void reparentOOBObjects(); /// - bool buildPolyList(PolyListContext context, AbstractPolyList* polyList, const Box3F& box, const SphereF& sphere) override; - bool buildExportPolyList(ColladaUtils::ExportData* exportData, const Box3F& box, const SphereF&) override; + bool buildPolyList(PolyListContext context, AbstractPolyList* polyList, const Box3F& box, const SphereF& sphere) override { return false; }; + bool buildExportPolyList(ColladaUtils::ExportData* exportData, const Box3F& box, const SphereF&) override { return false; }; void getUtilizedAssets(Vector* usedAssetsList) override; }; #endif