Hello, so I need an npc to go through the path and it consists out of small tiles, which npc has to do :MoveTo() to. But I don’t know how to make these paths in order, so the NPC walks exactly to each path in the right order.
If you are still confused, we are able to see this system implemented in to Theme Patk Tycoon 2. The NPC has to basically walk on the selected path.
Media:
Theme park tycoon does not use the default pathfinding. They more likely used A* pathfinding in order to have a path finding system that can accommodate their grid based tile system, and identify the path tiles from the grid data.
I primarily learnt from @shvkti open source game. If you compare the python code and his code you will definitely see the similarities and be able to reap the explanations from the blog post withthe application code in the open source game which tbh you can copy and paste if you understand it.
Also for NPC movement I recommend no humanoids, as they are pretty laggy as they use physics to travel, lots of physics = lag due to collisions and such. Tweening is recommended like in theme park tycoon they don’t collide with each other.
Thanks. I am pretty sure I still need to use humanoid due to me making a fight system between the npcs. But your answer is appreciated a lot. Thank you!