namespace Zinnia.Rule
{
using UnityEngine;
using Zinnia.Data.Type;
///
/// Determines whether a given is within the range of the specified .
///
public class FloatInRangeRule : FloatRule
{
[Tooltip("The range in which the given float must be equal to the bounds or within the range.")]
[SerializeField]
private FloatRange range;
///
/// The range in which the given must be equal to the bounds or within the range.
///
public FloatRange Range
{
get
{
return range;
}
set
{
range = value;
}
}
///
protected override bool Accepts(float targetFloat)
{
return Range.Contains(targetFloat);
}
}
}