I'm wondering if anyone can give me some hints.
I want to build a navmesh from the brushes. If you dont know what a navmesh is, it is just a set of polygons on which the AI can navigate. It is much more robust than waypoints, and I think I know how to combine them into convex polygons so it could be done automatically, if I knew what polygons I wanted first. To start I just want to find the floors. So to make it simple, I want all the poly's in the map with a normal of (0,0,1). This won't work but it is a start, as it won't know if it is reachable from a given plane or not but keep it simple for now.
Now I looked around in the code and thought I could use the planes data on the models, but unfortunately the ceilings plane normal also points up too. So I figure I will have to walk the BSP tree and find all the leafs and calculate the polygon normals manually.
Unless you think there is a better way.
If you got any advice I'd be happy to hear from you.
I want to build a navmesh from the brushes. If you dont know what a navmesh is, it is just a set of polygons on which the AI can navigate. It is much more robust than waypoints, and I think I know how to combine them into convex polygons so it could be done automatically, if I knew what polygons I wanted first. To start I just want to find the floors. So to make it simple, I want all the poly's in the map with a normal of (0,0,1). This won't work but it is a start, as it won't know if it is reachable from a given plane or not but keep it simple for now.
Now I looked around in the code and thought I could use the planes data on the models, but unfortunately the ceilings plane normal also points up too. So I figure I will have to walk the BSP tree and find all the leafs and calculate the polygon normals manually.
Unless you think there is a better way.
If you got any advice I'd be happy to hear from you.
Comment