Files
2023-04-27 11:32:47 +03:00

28 lines
742 B
C#

using UnityEngine;
public class BlockState : BlockParentState
{
public override void UpdateLogic(PlayerNetwork player)
{
base.UpdateLogic(player);
player.animation = "Block";
player.animationFrames++;
player.velocity = new DemonicsVector2(player.velocity.x, 0);
ToIdleState(player);
}
private void ToIdleState(PlayerNetwork player)
{
if (player.stunFrames <= 0)
{
BlockParentState.skipKnockback = false;
player.player.StopShakeCoroutine();
CheckTrainingComboEnd(player);
EnterState(player, "Idle");
}
}
protected override void OnEnter(PlayerNetwork player)
{
base.OnEnter(player);
}
}