Example #1
0
    private void AttackAbility()
    {
        if (Input.GetMouseButtonDown(0))
        {
            Instance.SetAttackAnimation();
        }

        // For now, disable secondary mode.
        // if (Input.GetMouseButton(1) && !IsManuallyMoving() && !Game.Instance.isInteractingWithUI)
        // {
        //     ActorAttack.EnsureInSecondaryMode();
        // }
        // else
        // {
        //     ActorAttack.EnsureStopSecondaryMode();
        // }

        bool charging = Input.GetMouseButton(0) && !Game.Instance.isInteractingWithUI && CanUsePA();

        Anim.SetBool("Attacking", charging || Anim.GetBool("SecondaryMode"));
        Anim.SetBool("Charging", charging);
    }