punish v6.8.18.0
This commit is contained in:
commit
cfb4dea47e
316 changed files with 554088 additions and 0 deletions
|
@ -0,0 +1,16 @@
|
|||
using System.Numerics;
|
||||
|
||||
namespace Questionable.Controller.NavigationOverrides;
|
||||
|
||||
internal sealed record BlacklistedArea(ushort TerritoryId, Vector3 Center, float MinDistance, float MaxDistance, bool RecalculateNavmesh = false) : IBlacklistedLocation
|
||||
{
|
||||
public AlternateLocation? AdjustPoint(Vector3 point)
|
||||
{
|
||||
float num = (point - Center).Length();
|
||||
if (num < MinDistance || num > MaxDistance)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return new AlternateLocation(Center + Vector3.Normalize(point - Center) * MaxDistance, RecalculateNavmesh);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue