using System.Threading.Tasks;
using Godot;

namespace Cirno.Scripts.Components.FSM._3DPlayer;

public partial class Init : BaseState<PlayerState, CharacterBody3D>
{
    public override PlayerState StateId => PlayerState.Init;
    
    public override void EnterState()
    {
        // _storageModule.FacingDirection = ((PlayerStateMachine)StateMachine).StartingDirection;
        // _animationProvider.PlayUnteleportAnimation();
         _ = AutoSwitchToStart();
    }

    public override void ExitState()
    {

    }

    public override void PhysicsProcessState(double delta)
    {

    }

    public override void ProcessState(double delta)
    {

    }

    private async Task AutoSwitchToStart()
    {
        await Task.Delay(500);
        StateMachine.SetState(PlayerState.Active);
    }
}