Repository navigation
ntre_marketa_ctg: navmesh rework - #147
sunzenshen wants to merge 4 commits into
Conversation
One file. Against master: 1051 -> 833 areas, 605,273 -> 359,509 bytes; areas the engine blocks at every round start 15 -> 0; the kiosk ghost spawn, stranded on master, is reachable. - Sliver areas merged into their neighbors on the same floor. - The room around ghost spawn 1 (470,-599), which master leaves unmeshed, is meshed. Its two doorways hold hinged physics doors; each door strip is split at the closed door, so the engine's round-start test does not block the doorways. - The kiosk ghost spawn (679,1331) is linked to the market through the 40 u gap in its wall by a strip area. - Props: floor under props bots stood pressed against is cut out (market stalls, diagonal props and poles, table and chair sets, and the dock plank near the attacker spawn - motion disabled, it can only break). Areas the engine blocks at every round start removed. - Walk links a player hull cannot cross are cut (a market stand, a fence door, a scooter, recycle bins, a firebox, world brushes, a corner-only link), and the areas left with no way in removed. - Pockets nothing can enter are removed: a sealed 18-area island behind a wall at (-854,781), and 40 areas in 12 pockets whose way in is an 87-337 u climb or blocked by the engine. - Re-analyzed in game after the edits.
Renumbers area and ladder ids only, so an id-keyed diff against master reads sensibly: 804 of the 833 areas carry the id of the master area they match; master's ladder keeps id 1. Areas are matched only within 64 u of height. Geometry, connections, attributes and the analyzed visibility data are unchanged (verified topology-identical).
The back alleys west of the market hold ghost spawns 5 (-721,-1007) and 14 (-258,-1038) and had no nav areas, on master either, so bots never fetched the ghost there. 12 areas are added, drawn on the floor a player hull can stand on, all links both ways: - a 40 u passage (y -872..-833) from the market floor at area 516 (extended 10 u to meet it), a corridor west to the alley, and the north-south alley itself with spawn 5 at its south end (a fixed chain-link fence door closes it there); - a stairwell from the corridor's west end up 160 u to the walled landing that holds spawn 14. Not meshed: the alley's north exit, a 34 u gap between a wall and a stall's back (1 u clearance a side for a player over 90 u), and a side room off the alley. No fall anywhere on the new areas. With the ghost pinned at either spawn bots now fetch it in every match (10 of 10 at each, about 25 s; master 0 of 10). Re-analyzed in game; ids of existing areas unchanged, new areas take 2994-3005.
An outside review of this mesh found walk links that run one way only and climbs whose drop back was cut. Each one-way pair was swept with a player hull in both directions by the engine's hull audit: - Restore the missing direction of the three pairs clear both ways, and of the two that only movable props block (a crate, the stools at a stall), which bots meet as they stand at run time. - Cut both ways the pair through the concrete wall near (-100, -2225). Delete five areas the half cuts ended in that no player hull fits in: inside a fire box, a parked scooter (a static prop), two wall slivers, and beside a stairwell handrail. - Restore the drop from nine wall-top strips and ledges whose climb was kept; cut the two climbs that run into a post and a neon sign. Beyond the review, from the same audit: delete six more areas no player hull fits in (the fire box's other half, inside an awning, a recycle bin, a security bank, a wall by the stairwell), and cut two pairs blocked both ways by a market stand and a luggage rack. Existing areas keep their ids. Re-analyzed in game (same graph, fresh visibility).
|
@sunmachine this map is still not really considered "fixed" but I think it's a illustrative example of how just fixing OnStuck events isn't quite enough, as there's tons of winding elevated shortcuts that the nav_generate automated navmeshes miss, like this elevated loft that has no connections:
This would be an interesting use case for nav editing functionality in Wireframe. |
Actually @DommHavaiGreyish fixed a lot of these edge cases already in #159 , and I was able to verify that his fixes cover the same areas I had concerns with:
There's some edge cases left like the board crossings:
... but these diagonal areas are actually hell to navmesh by hand (and don't have a way to toggle based on destructability), so I'm going to close this PR in favor of Domm's version. |
Add rooftop navmesh areas to the Marketa CTG navmesh. Builds on the base mesh from #147 (sunzenshen), which these changes are based on. Co-authored-by: sunzenshen <sunzenshen@gmail.com>
|
Closed in favor of #159 |




ntre_marketa_ctg: navmesh rework
One file,
neo/maps/nav/ntre_marketa_ctg.nav. It was measured on upstream master (at #2168) plus the draft NeotokyoRebuild/neo#2176 (then only its unwanted-ladder release, now its changes 1 and 7) and NeotokyoRebuild/neo#2186 ("Bots skip weapons they cannot reach", merged since), with harness logging added.Dependencies and status
Needs (worse than master, or broken, without it):
Helped by (measured better with it; the mesh does not wait on it):
Pending before review:
At a glance
Four commits:
1. What changed
func_physboxon aphys_hinge). After every round restart the engine tests a hull-sized box at the center of each nav area and blocks the area for the round if the box is in solid; brush entities count, and onlyfunc_doors and breakables are walked through. The closed door stood in the middle of both door strips, so both were blocked until a later re-test caught a door pushed open. A bot that picked up the ghost inside with both doors shut had no path out: in an earlier revision one of eight rounds with the ghost at that spawn ended in a stalemate, the carrier standing in the room for 165 s. Each door strip is now split at the closed door's plane, so no center test lands on a door; the door lies on the edge between the two pieces, and bots push it open walking through, as they do going in for the ghost.2. Id alignment
804 of the 833 areas carry the id of the master area they match; master's ladder keeps id 1. Areas are matched only within 64 u of height. Geometry, connections, attributes and the analysis data are unchanged by this step (verified topology-identical). Commit 3 keeps every existing id; its new areas take 2994-3005.
3. The back alleys
West of the market, the back alleys hold ghost spawns 5 (-721, -1007) and 14 (-258, -1038). On master the nearest nav area is 521 u from spawn 5, and for spawn 14 it is the market floor 160 u below its landing, behind the alleys' wall, so bots never fetched the ghost from them (0 of 10 matches each with the ghost pinned there). 12 areas are added, drawn over the floor a player can stand on (16 u in from each wall), every link both ways:
Not meshed: the alley's north exit, a 34 u gap between a wall and the back of a market stall, which leaves 1 u a side for a player over 90 u (the engine's own
nav_generatedoes not link it either), and a side room off the alley with two movable stools. Nothing on the new areas can be fallen from. With the ghost pinned at either spawn, bots now fetch it in every match (10 of 10 at each, first pickup after about 25 s).4. Review fixes
An outside review of the mesh listed walk links that run one way only and climbs whose drop back was cut. Every one-way pair was swept with a player hull both ways by an engine hull audit (a harness-only test build: a hull is stood every 4 u on every area and swept every 4 u across every link), and the mesh's level links were checked the same way.
From the review:
Beyond the review, from the same audit (bot positions from 112 matches on this mesh):
prop_dynamic), the security bank near (620, -604), and the wall by the stairwell near (212, -2234).Every kept area keeps its id. Re-analyzed in game.
How it was tested
BLOCKED_LINKS map=ntre_marketa_ctg level_pairs=1237 oneway=0 keep=0 cut=1 area=7 check=1 entity=23: the cut is the kitchen counter link and the area rows the sakura planter's trunks, both kept above; the entities are the physics props and the hinged doorstrigger_hurtand no drop that kills. The only deaths not caused by another player are bots standing on a movable crate at (167, 1035): 11 in 80 matches on master, 3 in 80 here. No area needsPRECISEorCLIFFmarks..nav, run back to back. CTG, 2 rounds of 3 minutes with the ghost pinned at each of the 20 ghost spawns in turn, 4 runs each, 30 bots, default weapon damage, 8 matches at a time; every match reached match end with 0 asserts and no crash. The stuck count isOnStuckplusFAIL_STUCKmove failures, excluding the spawn crush at round start and the weapon-scavenging behavior.OnStuck73.9 -> 39.4FAIL_NO_PATH_EXISTSmove failures 5.5 -> 3.3 a match (paired x1.05 [0.83, 1.34], 31 pairs down, 35 up). Master's mean carries one match with 237: a bot got into the kiosk, which master strands, picked up the ghost and had no path out. Without the kiosk spawn, 2.6 -> 3.3 (x1.12 [0.90, 1.39]). None of this mesh's are in the alleys; they come in bursts, 5-8 bots at once as a ghost carrier runs or drops the ghost, and more rounds here have a carrier. "Fell off the path" failures 0.1 -> 0.1FAIL_NO_PATH_EXISTS3.4 -> 2.8; every match reached match end with 0 asserts and no crash. The rise sits at a spot no edit touches, the table and chairs at (800, 1270) (physics props with their motion disabled), already this mesh's busiest spot (206 stuck events in the 112 earlier matches): 56 -> 98 here, spread over 18 / 19 runs. Without that area, 10.7 -> 10.1 a match, x1.03 [0.78, 1.36].The dock plank
The board by the attacker spawn, a
prop_physics(dockplank01bat (383, -1754, 57)), lies across the floor from the ground at x 285 to 50 u up at x 481. Bots leaving the spawn crossed it where it stands 14-21 u up, more than a step, and stuck: it was the top stuck spot on master. It is a physics prop, but it cannot move: its motion is disabled (spawn flag 8), and it has no input or damage threshold that enables motion. It can break (50 health). So for pathing it is static until it is shot apart, and after that the carved band is 80 x 70 u of floor bots do not use. The band is cut where the board stands more than a step up; paths cross over its low end.Known, not changed