Files
2025-11-14 22:36:20 +00:00

23 lines
730 B
C#

using Terraria.ModLoader;
using Terraria;
namespace ForgottenWawiTech.Content.Players
{
// Tracks per-tick emission cooldown for BeamAttackWand while swinging.
public class BeamAttackWandPlayer : ModPlayer
{
public int BeamEmissionTimer = 0;
public float LastBeamRot; // smoothed rotation used to cluster beams
public override void ResetEffects()
{
// If not holding the wand, allow immediate beam spawn next time it's used and reset rotation smoothing.
if (Player.HeldItem.type != ModContent.ItemType<Items.Weapons.Magic.BeamAttackWand>())
{
BeamEmissionTimer = 0;
LastBeamRot = 0f;
}
}
}
}