Final effect
plug-in link:
https://download.csdn.net/download/qq_36303853/87762376
import AI plug-in
Create a new empty object, add the PathFinder component, and use
it to render the navigation path in map navigation. The blue part drawn is the walkable area, and the non-blue area is the collider area I configured. You can modify it yourself. If you are not satisfied, you can modify Diameter value, to control how large the collider area is and cannot walk
. Add a collider to the enemy, and the collision area will adjust itself
. Add an AIPath component to the enemy, our 2d project here,记得orientation先选择YAxisForward(for 2D games)