Insanely huge initial commit

This commit is contained in:
2026-02-21 17:04:05 -08:00
parent 9cdd36191a
commit 613d75914a
22525 changed files with 4035207 additions and 0 deletions

View File

@@ -0,0 +1,57 @@
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
namespace Michsky.MUIP
{
[ExecuteInEditMode]
public class UIManagerAnimatedIcon : MonoBehaviour
{
[Header("Settings")]
public UIManager UIManagerAsset;
[Header("Resources")]
public List<GameObject> images = new List<GameObject>();
public List<GameObject> imagesWithAlpha = new List<GameObject>();
void Awake()
{
if (UIManagerAsset == null) { UIManagerAsset = Resources.Load<UIManager>("MUIP Manager"); }
this.enabled = true;
if (UIManagerAsset.enableDynamicUpdate == false)
{
UpdateAnimatedIcon();
this.enabled = false;
}
}
void Update()
{
if (UIManagerAsset == null) { return; }
if (UIManagerAsset.enableDynamicUpdate == true) { UpdateAnimatedIcon(); }
}
void UpdateAnimatedIcon()
{
for (int i = 0; i < images.Count; ++i)
{
if (images[i] == null)
continue;
Image currentImage = images[i].GetComponent<Image>();
currentImage.color = UIManagerAsset.animatedIconColor;
}
for (int i = 0; i < imagesWithAlpha.Count; ++i)
{
if (imagesWithAlpha[i] == null)
continue;
Image currentAlphaImage = imagesWithAlpha[i].GetComponent<Image>();
currentAlphaImage.color = new Color(UIManagerAsset.animatedIconColor.r, UIManagerAsset.animatedIconColor.g, UIManagerAsset.animatedIconColor.b, currentAlphaImage.color.a);
}
}
}
}