I absolutely love the pathfindingservice, I think it’s really neat. However there is a complaint that I have.
I noticed that it ignores parts with cancollide set to false as obstructions.
And while this makes sense logically, in the game world if you ever want to have invisible parts as obstructions that you want NPCS to walk around but that you want player characters to be able to pass through.
The pathfinding essentially ignores the market stalls because there isn’t enough obstruction. However as you can see, I created a box around it to act as a physical obstruction so they walk around the stalls rather than pass through them. The only problem is, it only works if cancollide is set to true, which means player characters will experience this weird invisible box around market stalls.
I don’t want to make this “my issue”, but I’m sure there are other developers who would agree that the pathfindingservice shouldn’t ignore parts with cancollide set to false, or we should at least be given the option to enable it/disable it ourselves. Thanks : )
If you are using FilteringEnabled (which you should be) then you are able to overcome this issue. Create a model containing all the parts you want the paths to take into account, when the client has loaded then delete the parts from the client. Any pathfinding calls you make will take these parts into account since the server is doing the calculations and not the client.
Yes I’m using FilteringEnabled, but the calculations are done by the client. I could have the server do it I suppose but I still think they should give us a little bit more freedom.
[quote] Yes I’m using FilteringEnabled, but the calculations are done by the client. I could have the server do it I suppose but I still think they should give us a little bit more freedom. [/quote]I am pretty sure the calculations are still done on the server regardless. Either way, since these are NPCs if this game is multiplayer than you should be doing it with the server.