3D RTS pathfinding
Posted 15 April 2012 - 03:05 PM
Basically, in the game I'm making, there will be agents with different sizes of OBB collision boxes.
I can use steering behaviours for avoiding other agents, so I don't need complete dynamic pathfinding. However, there is a problem because different agents have different collision geometry, and structures can be placed in almost any place.
This means that there might be a gap between two structures where some agents can go through and some can't.
A solution I have found to this problem is to do a sweep of the collision geometry of the agent from start node of the edge the pf algorithm is currently testing, to the end node of that edge. But this is probably a bit overkill since every edge the algorithm tests would also have to create and test with a collision geometry sweep.
What are some reasonable approaches to this problem?
Posted 15 April 2012 - 05:28 PM
Otherwise you might want tot try implementing some sort of navigation mesh. It describes the area where your entities can walk, so you could cut holes in it where static obstacles are placed, and make sure no navigation mesh border is smaller than the width of your collision geometry.
Posted 15 April 2012 - 05:41 PM
A navmesh might be a more elegant solution (although I struggle to see how this would fix my problem with the different collision geometry) but I'd prefer not to use it, because my entire system is currently relying on waypoints.
Posted 16 April 2012 - 12:20 AM
Posted 16 April 2012 - 02:25 AM
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users