private static bool abort_handler(BehaviorTask node, Agent pAgent, object user_data) { if (node.m_status == EBTStatus.BT_RUNNING) { node.onexit_action(pAgent, EBTStatus.BT_FAILURE); node.m_status = EBTStatus.BT_FAILURE; node.SetCurrentTask(null); } return(true); }
private static bool end_handler(BehaviorTask node, Agent pAgent, object user_data) { if (node.m_status == EBTStatus.BT_RUNNING || node.m_status == EBTStatus.BT_INVALID) { EBTStatus status = (EBTStatus)user_data; node.onexit_action(pAgent, status); node.m_status = status; node.SetCurrentTask(null); } return(true); }
private static bool abort_handler(BehaviorTask node, Agent pAgent, object user_data) { if (node.m_status == EBTStatus.BT_RUNNING) { node.onexit_action(pAgent, EBTStatus.BT_FAILURE); node.m_status = EBTStatus.BT_FAILURE; node.SetCurrentTask(null); } return true; }