soundvision/UnityProject/Assets/Scenes/Examples/VisualEffectGraph/script/FlareBind.cs
2020-03-04 21:47:24 +01:00

13 lines
328 B
C#

using UnityEngine;
using UnityEngine.VFX;
public class FlareBind : MonoBehaviour
{
[SerializeField] private VisualEffect flareEffect = null;
private static readonly string Spread = "spread";
public void OnEnergyChanged(float energy)
{
flareEffect.SetFloat(Spread, energy * 0.1f + 0.1f);
}
}