mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
Merge pull request #2204 from Azaezel/badPrefabEntryHandling
don't try to physically interact with a prefab with invalid entries
This commit is contained in:
commit
4338bdc368
|
|
@ -528,6 +528,11 @@ bool Prefab::isValidChild( SimObject *simobj, bool logWarnings )
|
|||
bool Prefab::buildPolyList(PolyListContext context, AbstractPolyList* polyList, const Box3F &box, const SphereF& sphere)
|
||||
{
|
||||
Vector<SceneObject*> foundObjects;
|
||||
if (mChildGroup.isNull() || mChildGroup->empty())
|
||||
{
|
||||
Con::warnf("Bad Prefab Config! %s has no valid entries!", getName());
|
||||
return false;
|
||||
}
|
||||
mChildGroup->findObjectByType(foundObjects);
|
||||
|
||||
for (S32 i = 0; i < foundObjects.size(); i++)
|
||||
|
|
|
|||
Loading…
Reference in a new issue