Hi i have been struggling with creating the best path system for my game. The game is 4 directional and I basically spawn like 20 enemies and i want them to all search for their own path to the player. The issue with the standard pathfinding is they all take the same path , even when i give them different spawn points they all end up walking the same way.
The methods i already tried are waypoints, i made 4 waypoints and pinned them to the player and made the enemies randomly pick a waypoint. My issue with the waypoints are that the random event picks the same waypoint a lot and then sometimes the enemy will walk past the player to get to the waypoint(which i can stop with an invisible sprite ) but most importantly all the enemies can’t get to the waypoint because they’ll just line up.
So i tried to use easystar. Js i might be using it wrong but my issue with that is for some reason the enemies stop moving at random times unless i move the player and they don’t all take different paths like in the example i seen they seem to all group together .
I’m looking for alternative ways to make enemies take different ways to get to the player, if two enemies go to his left side and then two above him and below and then the right then they all surround that would be ideal