AK056/Assets/Plugins/PrimeTween/Demo/Scripts/HighlightableElement.cs
2025-05-08 13:38:55 +08:00

17 lines
472 B
C#

#if PRIME_TWEEN_INSTALLED
using UnityEngine;
namespace PrimeTweenDemo {
public class HighlightableElement : MonoBehaviour {
[SerializeField] public Transform highlightAnchor;
public MeshRenderer[] models { get; private set; }
void OnEnable() {
models = GetComponentsInChildren<MeshRenderer>();
foreach (var mr in models) {
_ = mr.material; // copy shared material
}
}
}
}
#endif