AI BT won't return to patrol after losing sight of player

I’m working with a waypoint system which I have fed into a behaviour tree to make my AI patrol specific locations. Whenever my AI perceives a player, it chases until losing sight. When it loses sight, it remains in place and will not return to the patrol. when I review the BT, it seems to be playing the chase function despite making no means to look in the players direction or try to follow player movement.

As you can see, it patrols fine and the patrol function plays when the game starts:


When the player enters the AI’s sight and leaves it seems to get stuck trying to end the tree and return back to previous function:

the functionality for the scripting is as follows:
Decorator which sits on the chase sequencer:


Variables of the service on the chase sequencer:

Variables attacked to the patrol sequencer:

The logic seems fine to me in so much as it should see that the target player has left the sight of the AI and return to previous function.

I have this same script on another AI which random roams instead and this has no issues. It uses the exact same logic as the patrolling AI other than a random roam instead of specific waypoints.

This is the chase logic which is set the same on all of my AI:

AI controller sense set up:

Would very much appreciate any input that could help explain this behaviour. If any more information is needed to help, I’d be happy to provide.

Much thanks in advance guys.

Nevermind. I fixed it. On the branch which checks if theres a succesful sight sensed, i forgot to slot false to do anything. A good lesson in stepping side and doing something else for a bit.