public void CmdClearActions(GameObject agent) { if (Helper.IsNullOrDestroyed(agent)) { DebugManager.WarningMessage("Attempting to add an AIAction to an AIAgent Server side!"); return; } AIAgent ai = agent.GetComponent <AIAgent>(); if (ai) { ai.ClearAllActions(); } }