Method IsAngleInRange
IsAngleInRange(float, float, float)
Determines whether a specified angle is within the range defined by the initial and end boundaries.
public static bool IsAngleInRange(float angle, float init, float end)
Parameters
anglefloatThe angle to evaluate, in degrees.
initfloatThe inclusive lower bound of the range, in degrees.
endfloatThe exclusive upper bound of the range, in degrees.
Returns
- bool
true if the angle is greater than or equal to the initial boundary and less than the end boundary; otherwise, false.
Remarks
The comparison is inclusive of the initial boundary and exclusive of the end boundary. This method does not normalize the angle; callers should ensure the values are in the expected range if wrap-around behavior is required.