Quote:
Originally Posted by _Z3phyr_
You can find which quadrant the player is in with a dir = getdir(player.x-x,player.y-y)... or is it the other way around... whatever... and then find the clearest path in that quadrant maybe?
I'm just throwing out stuff here though
|
Yeah, that's where zig-zagging paths come in.
We have some levels that are maze-like. The player may be to the left of the NPC, but the proper path begins to the right; a path going somewhere else begins to the left.
The NPC would try to go down the wrong path, catch a wall and find no way to the player, then spazz and crash the server with a lot of loops.