book_4_sparkGenerated
code_blocksInput

Description

The y field in the RangedFloat struct represents the upper bound of the float range. It is marked as obsolete and should not be used in new code. Instead, use the Max property to access the maximum value of the range.

Usage

To access the maximum value of a RangedFloat, use the Max property instead of the y field. The y field is maintained for backward compatibility but is not recommended for use in new implementations.

Example

// Example of using RangedFloat
RangedFloat rangedFloat = new RangedFloat();

// Accessing the maximum value using the recommended property
float maxValue = rangedFloat.Max;

// Obsolete usage (not recommended)
#pragma warning disable 0618 // Disable obsolete warning
float obsoleteMaxValue = rangedFloat.y;
#pragma warning restore 0618 // Restore warning