We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a22503a commit a80a5e5Copy full SHA for a80a5e5
Managers/MovableMan.cpp
@@ -1110,9 +1110,12 @@ bool MovableMan::ValidateMOIDs() {
1110
// Description: Indicates whether the passed in MovableObject pointer points to an
1111
// MO that's currently active in the simulation, and kept by this MovableMan.
1112
1113
-bool MovableMan::ValidMO(const MovableObject *pMOToCheck)
1114
-{
1115
- return pMOToCheck && pMOToCheck->GetID() != g_NoMOID;
+bool MovableMan::ValidMO(const MovableObject *pMOToCheck) {
+ if (pMOToCheck && pMOToCheck->GetID() != g_NoMOID && pMOToCheck->GetParent() == nullptr) {
+ return true;
1116
+ } else {
1117
+ return IsActor(pMOToCheck) || IsDevice(pMOToCheck) || IsParticle(pMOToCheck);
1118
+ }
1119
}
1120
1121
0 commit comments