| 4657 | } |
| 4658 | |
| 4659 | bool CSmartObjectManager::PrepareNavigateSmartObject(CPipeUser* pPipeUser, const GraphNode* pFromNode, const GraphNode* pToNode) |
| 4660 | { |
| 4661 | // Sanity check that the nodes are indeed smart object nodes (the node data is accessed later). |
| 4662 | if (pFromNode->navType != IAISystem::NAV_SMARTOBJECT || pToNode->navType != IAISystem::NAV_SMARTOBJECT) |
| 4663 | { |
| 4664 | if (gAIEnv.CVars.DebugPathFinding) |
| 4665 | { |
| 4666 | AILogAlways("CAISystem::PrepareNavigateSmartObject %s one of the input nodes is not SmartObject nav node.", |
| 4667 | pPipeUser->GetName()); |
| 4668 | } |
| 4669 | return false; |
| 4670 | } |
| 4671 | |
| 4672 | CSmartObject* pObject = pFromNode->GetSmartObjectNavData()->pSmartObject; |
| 4673 | CSmartObjectClass* pObjectClass = pFromNode->GetSmartObjectNavData()->pClass; |
| 4674 | SmartObjectHelper* pFromHelper = pFromNode->GetSmartObjectNavData()->pHelper; |
| 4675 | SmartObjectHelper* pToHelper = pToNode->GetSmartObjectNavData()->pHelper; |
| 4676 | |
| 4677 | return PrepareNavigateSmartObject(pPipeUser, pObject, pObjectClass, pFromHelper, pToHelper); |
| 4678 | } |
| 4679 | |
| 4680 | // Called to prepare PipeUser state ready to use a navigation SO. Returns true if successful. |
| 4681 | bool CSmartObjectManager::PrepareNavigateSmartObject(CPipeUser* pPipeUser, CSmartObject* pObject, CSmartObjectClass* pObjectClass, SmartObjectHelper* pFromHelper, SmartObjectHelper* pToHelper) |
no test coverage detected