AI avoid hazard/laser

Hi Folks!

Is there a way to avoid hazard zones for the AI? There’s a toggleable laserbeam and I just want to ‘tell’ the AI to not enter/cross the beam if the laser is active. Of course I could create a collisionbox with the size/lenght of the laserbeam so it influences the navmesh and turn it on and off in sync with the laser. Maybe there’s a smarter solution without manipulating the navmesh…

If you were making a 3D game, I would suggest using Environment Queries. However, in this case, I believe your solution is correct.

Hey there @SmallLebowski! Welcome back to the community! If you’re using NavMesh, the method you described is the best. However if you were using your own pathfinding, I’d set up avoid fields.

Alright! Thank you both for your help! :+1: