Trouble with PathFinding

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By AkaiTobira

Hello All,
I am newbie so sorry for my English and other mistakes.
I am currently working on Dungeon Crawler game which generate his own mazes from segments. Patterns of segments have only enters, walls and floors. During the generation i am filling it by many const objects, barrels, chest and moobs. And now I have a problem. How to design a PathFinding for mobs? They have to avoid const objects to come close enough to hurt the player.

I have a scene called RandomMap which have Segments, Segments have only TileMaps handling walls and floors. Mazes are big, so i can’t cover it by one NavigationPolygoneInstance. Also everything what i am putting is a separate scene.

I will be thankful for any suggestions.
Akai

You can implement pathfinding using A*, or define steering behavior for your mobs, with collision avoidance.

Diet Estus | 2018-09-14 22:54

Can You tell me more about steering behavior ? I tried to use builded in A* but graph was too big and whole game paused for calculation time.

AkaiTobira | 2018-09-15 12:48

:bust_in_silhouette: Reply From: Diet Estus

KidsCanCode has a good tutorial covering the basics. Once you implement simple seek behavior, you can then refine it by adding collision avoidance. See here.