Environment Query Question

Hi all,
I have a quick question if any body can help. Ive created a environment query on my AI character which scores the best place that the main character is hiding and then goes to that location, which works great. However if there is no hiding spot, ie the query returns all 0’s my AI character just runs on the spot. How do i set it so that if the query only returns 0’s then it should default back to its Idle state (another branch of the behavior tree) ?

When EQS query fails to produce any results the Run EQS Query task fails, so to have AI move just put the EQS task in sequence with a Move task, and make that sequence be a child of a selector whose second child would be the idle behavior.

Like so :slight_smile:

Cheers,

–mieszko

Thanks MieskoZ,
It took alittle tweaking to get it to work how i wanted, but got there in the end. If anyone else is interested this is how i got there. I now just need to work out how to rotate the AI correctly as at the moment he just snaps to the rotation of travel.