void Start() { if (adjustHue) { adjustHue.value = HSVRange.GetHue(targetMaterial); adjustHue.onValueChanged.AddListener(hue => { HSVRange.SetHue(targetMaterial, hue); }); } if (adjustSaturation) { adjustSaturation.value = HSVRange.GetSaturation(targetMaterial); adjustSaturation.onValueChanged.AddListener(saturation => { HSVRange.SetSaturation(targetMaterial, saturation); }); } if (adjustValue) { adjustValue.value = HSVRange.GetValue(targetMaterial); adjustValue.onValueChanged.AddListener(value => { HSVRange.SetValue(targetMaterial, value); }); } if (adjustAlpha) { adjustAlpha.value = HSVRange.GetAlpha(targetMaterial); adjustAlpha.onValueChanged.AddListener(alpha => { HSVRange.SetAlpha(targetMaterial, alpha); }); } }
public void SetValue(float value) { HSVRange.SetValue(targetMaterial, value); }