Description
The RangedFloat.x
field represents the lower bound of a range for a floating-point number. It is a public instance field of type System.Single
(float). However, this field is marked as obsolete and should not be used in new code. Instead, use the RangedFloat.Min
property to access the minimum value of the range.
Usage
Although RangedFloat.x
is accessible, it is recommended to use the RangedFloat.Min
property for accessing the minimum value of a RangedFloat
instance. This ensures compatibility with future updates and maintains code clarity.
Example
// Example of using RangedFloat.Min instead of the obsolete RangedFloat.x
RangedFloat rangedFloat = new RangedFloat();
float minValue = rangedFloat.Min; // Recommended way to access the minimum value
// Obsolete usage (not recommended)
// float obsoleteMinValue = rangedFloat.x;