Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: IIKII on January 18, 2017, 08:04:35 AM

Title: Navmesh path check?
Post by: IIKII on January 18, 2017, 08:04:35 AM
Hi, I am using navmesh for my enemy AI but there's some problems that I dont understand.

I put my player as the enemy's agent destination and if the player is out of the range of the blue navigation area, the enemy will stop chasing but there's no good action to check if the destination path is out of range..

I tried using actions like 'path is stale', 'check path status' and other ones but none of them is working as I thought to be.

Am I missing some key knowledge on using navmesh?
Title: Re: Navmesh path check?
Post by: 600 on January 18, 2017, 10:24:24 AM
Maybe you can check distance and if more than X, stop chasing.
Title: Re: Navmesh path check?
Post by: terri on January 18, 2017, 10:46:36 AM
try setting the player as the destination, waiting like 0.1 and then use check path status
Title: Re: Navmesh path check?
Post by: IIKII on January 19, 2017, 12:38:27 AM
Wait for 0.1 and using path status > 'Path undefined event' works for checking if the destination is outside the blue navigation.

Thanks..