public void MoveTarget(DetourAgent agent, Vector3 target) { Assert.IsTrue(_crowd.Handle.ToInt64() != 0); Assert.IsTrue(_tileCache.NavQueryHandle.Handle.ToInt64() != 0); setMoveTarget(_tileCache.NavQueryHandle.Handle, _crowd.Handle, agent.ID, target.ToFloat(), false, agent.FilterIndex); }
public void RemoveAgent(DetourAgent agent) { Assert.IsTrue(_crowd.Handle.ToInt64() != 0); removeAgent(_crowd.Handle, agent.ID); agents.Remove(agent); }
public int AddAgent(DetourAgent agent, CrowdAgentParams ap) { Assert.IsTrue(_crowd.Handle.ToInt64() != 0); int idx = addAgent(_crowd.Handle, agent.transform.position.ToFloat(), ref ap); if (idx != -1) { agents.Add(agent); } return(idx); }
public int AddAgent(DetourAgent agent, CrowdAgentParams ap) { Assert.IsTrue(_crowd.Handle.ToInt64() != 0); int idx = addAgent(_crowd.Handle, agent.transform.position.ToFloat(), ref ap); if (idx != -1) { agents.Add(agent); } return idx; }