CapersProject/Assets/Plugins/AllIn1VfxToolkit/Scripts/All1VfxRandomTimeSeed.cs
SweetJJuya 11bc3b60ca 임시
2025-02-10 14:47:48 +09:00

17 lines
520 B
C#

using UnityEngine;
namespace AllIn1VfxToolkit
{
public class All1VfxRandomTimeSeed : MonoBehaviour
{
[SerializeField] private float minSeedValue = 0;
[SerializeField] private float maxSeedValue = 100f;
private void Start()
{
MaterialPropertyBlock properties = new MaterialPropertyBlock();
properties.SetFloat("_TimingSeed", Random.Range(minSeedValue, maxSeedValue));
GetComponent<Renderer>().SetPropertyBlock(properties);
}
}
}