/// <summary> ///cost are usualy distance * area cost /// </summary> public void SetGoalFindCover(float maxCost) { if (_canRecieveGoals == false) { return; } if (properties == null) { Debug.LogError("Agent dont have assigned Properties"); return; } if (!properties.canCover) { Debug.LogWarning("you trying to find cover when you dont even set properties to generate covers"); return; } lock (this) if (canSendCoverRequest == false) { return; } PathFinder.GetCover(this, maxCost, null, ignoreCrouchCost); }
public void SetGoalFindCover(int minChunkDepth, float maxCost) { if (_canRecieveGoals == false) { return; } if (!properties.doNavMesh) { Debug.LogWarning("you trying to find cover when you dont even set properties to generate covers"); return; } PathFinder.GetCover(this, minChunkDepth, maxCost, null, ignoreCrouchCost); }