i have these simple maze game and what i want to do is mack the hunter chasing the player while the player moves to the target .
I tried use set up like “Getting started tutorial” , and when i run the game the player go toward the target With no problem , but the hunter keeps shaking forward and backwards in its place until the player reach its target , then the hunter stops shaking and start moving toward the player Which is in the target.
i want to mack the hunter chasing the player smoothly as possible
Hi
The shaking is likely because the script used in the get started tutorial works, but it is not the best movement script you can write. Try using any of the other movement scripts in the package. For your use case I would recommend the AILerp movement script (make sure you use the latest version of the package if you want to use that). You can also add a SimpleSmooth modifier to your agent to smooth out the path a bit. Also, check out the example scene called ‘2D’ which shows how the AILerp script can be configured. You can simply set the ‘target’ field to the player and set the repath rate to 1 second or something and then it will work I believe.
Thanx a lot Aron … it work fine now