r2mods/ilspy_dump/ror2_csproj/EntityStates.VoidRaidCrab/SpinBeamWindUp.cs

31 lines
672 B
C#
Raw Normal View History

2024-10-04 07:26:37 +00:00
using RoR2;
using UnityEngine;
namespace EntityStates.VoidRaidCrab;
public class SpinBeamWindUp : BaseSpinBeamAttackState
{
public static AnimationCurve revolutionsCurve;
public static GameObject warningLaserPrefab;
public static string enterSoundString;
public override void OnEnter()
{
base.OnEnter();
CreateBeamVFXInstance(warningLaserPrefab);
Util.PlaySound(enterSoundString, base.gameObject);
}
public override void FixedUpdate()
{
base.FixedUpdate();
if (base.fixedAge >= base.duration && base.isAuthority)
{
outer.SetNextState(new SpinBeamAttack());
}
SetHeadYawRevolutions(revolutionsCurve.Evaluate(base.normalizedFixedAge));
}
}