ShopToolsUtilClamp(Single, Single, Single) Method

Clamp the supplied value within the allowed minimum and maximum values.

Definition

Namespace: ShopTools
Assembly: ShopTools (in ShopTools.exe) Version: 25.2429.4649
C#
public static float Clamp(
	float value,
	float minimum = 0f,
	float maximum = 1f
)

Parameters

value  Single
The value to clamp.
minimum  Single  (Optional)
The minimum allowable value.
maximum  Single  (Optional)
The maximum allowable value.

Return Value

Single
The caller's clamped value.

See Also