initial commit

This commit is contained in:
katboi01
2022-06-18 17:47:39 +02:00
parent 37e3de5719
commit d2fb3648db
256 changed files with 76340 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
using UnityEngine;
using UnityEngine.UI;
namespace HSVPicker
{
[RequireComponent(typeof(Image))]
public class ColorImage : MonoBehaviour
{
public ColorPicker picker;
private Image image;
private void Awake()
{
image = GetComponent<Image>();
picker.onValueChanged.AddListener(ColorChanged);
}
private void OnDestroy()
{
picker.onValueChanged.RemoveListener(ColorChanged);
}
private void ColorChanged(Color newColor)
{
image.color = newColor;
}
}
}