mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-12 15:14:35 +00:00
don't spool up new helper proxies if the goals are unchanged
This commit is contained in:
parent
2dae0fbbad
commit
57890a4327
2 changed files with 45 additions and 6 deletions
|
|
@ -194,7 +194,9 @@ DefineEngineMethod(AIController, getAimObject, S32, (), ,
|
|||
|
||||
"@see setAimObject()\n")
|
||||
{
|
||||
SceneObject* obj = dynamic_cast<GameBase*>(object->getAim()->mObj.getPointer());
|
||||
SceneObject* obj = NULL;
|
||||
if (object->getAim())
|
||||
obj = dynamic_cast<GameBase*>(object->getAim()->mObj.getPointer());
|
||||
return obj ? obj->getId() : -1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue