Enemy AI Sliding

Hello everyone,

I am making a FSM so my enemies can go between simple movement and path finding.

When in the BasicWalk state it simply does a look at and moves forward. Every so often it checks its old position and its current position; if there is no significant position change it determines that the enemy is stuck and goes to path finding.

It flicks between the two fine however when it bounces from AdvancedWalk the enemy slides until it bounces on the wall of the navmesh.

void Idle()
    {

        animation.CrossFade(idleClip.name);

        attackRechargeTimer -= Time.deltaTime;
        if ( attackRechargeTimer < 0 )
        {
            attackRechargeTimer = maxAttackRechargeTimer;
            hitBool = false;
        }

        if(!InRange())
        {
            state = State.BasicWalk;
        }
    }

    void BasicWalk()
    {
        animation.CrossFade(walkClip.name);

        Vector3 targetPostition = new Vector3( Target.transform.position.x, this.transform.position.y, Target.transform.position.z ) ;
        this.transform.LookAt( targetPostition );

        controller.SimpleMove((transform.forward * Speed) *Time.deltaTime);

        advancedWalkTimer -= Time.deltaTime;
        if ( advancedWalkTimer < 0 )
        {

            _oldPosition = _curPosition;
            _curPosition = transform.position;

            advancedWalkTimer = maxAdvancedWalkTimer;
            if(Vector3.Distance(_oldPosition, _curPosition)<advancedWalkRange)
            {
                state = State.AdvancedWalk;
            }
        }

        if(InRange())
        {
            state = State.Idle;
        }
    }

    void AdvancedWalk()
    {
        animation.CrossFade(walkClip.name);

        navMeshAgent.SetDestination(Target.transform.position);

        advancedWalkTimer -= Time.deltaTime;
        if ( advancedWalkTimer < 0 )
        {
            advancedWalkTimer = maxAdvancedWalkTimer;
            navMeshAgent.Stop();
            state = State.Idle;
        }

        if(InRange())
        {
            navMeshAgent.Stop();
            state = State.Idle;
        }
    }

Very sorry for the lack of comments but I do hope it is clear enough to see what I am aiming for. Any help would be great! Thanks in advance.

Just pumping this up.

Still looking for help, thanks.