Function JobRVO.BiasDesiredVelocity

BiasDesiredVelocity (UnsafeSpan<ORCALine> lines, ref float2 desiredVelocity, ref float2 targetPointInVelocitySpace, float maxBiasRadians)

Bias towards the right side of agents.

Public Static
bool BiasDesiredVelocity (

UnsafeSpan<ORCALine>

lines

ref float2

desiredVelocity

ref float2

targetPointInVelocitySpace

float

maxBiasRadians

)

Bias towards the right side of agents.

Rotate desiredVelocity at most [value] number of radians. 1 radian ≈ 57° This breaks up symmetries.

The desired velocity will only be rotated if it is inside a velocity obstacle (VO). If it is inside one, it will not be rotated further than to the edge of it

The targetPointInVelocitySpace will be rotated by the same amount as the desired velocity

Return

True if the desired velocity was inside any VO