Repository navigation
ntre_ballistrade_ctg: navmesh rework - #138
Merged
sunzenshen merged 4 commits intoOct 14, 2026
Merged
Conversation
One file. Against master: 1310 -> 933 areas, 1,192,466 -> 572,829 bytes; 19 areas no spawn or objective reaches (14 pockets) -> 0; 11 areas the engine blocks at every round start -> 0. - Areas CNavArea::UpdateBlocked finds solid at their center at round start are cut around the obstacle or dropped. - Standing room is carved around props, and a walk link a player hull cannot cross (past a signage stand) is cut. - Hand edits where test bots got stuck: the stair handrail over the one-way drop by 5076, a wall block, the doorway beside the window (PRECISE) and a motorcycle. - Raised tops a player can climb (46-54 u) get a one-way climb link; tops no bot can reach are removed. - Re-analyzed in game after the edits.
Renumbers area ids only, so an id-keyed diff against master reads sensibly: 928 of the 933 areas carry the id of the master area they match, kept ids that moved more than 64 u from their master location drop from 68 to 12, and the diff shows 5 added / 382 removed areas. Geometry, connections, attributes and the analyzed visibility data are unchanged (verified topology-identical).
sunzenshen
commented
Sep 28, 2026
sunzenshen
left a comment
Contributor
Author
There was a problem hiding this comment.
At an overview, most of the changes involved merging adjacent areas to form bigger ones to reduce the number of nodes bloating the nav file size and A* traversal space.
Before:
(Red means the area was deleted in the edits.)
After:
Doesn't seem to be any red flags in terms of deleted areas that shouldn't have been.
sunzenshen
marked this pull request as ready for review
September 28, 2026 07:30
Contributor
Author
An outside review of this mesh found walk links that run one way only. Each pair was swept with a player hull in both directions by the engine's hull audit: - Cut both ways the five pairs blocked both ways (clothing racks, the flatbed trailer); restore the missing direction of the two pairs clear both ways. - Restore 3440 -> 3437 past the signage stands near (1188, -1112). They are physics props, which bots meet as they stand at run time, so the link is kept both ways like the stands' other links. - Four climbs of 34-48 u onto wall tops and a crouch nook had lost their drop back; restore the drop. Delete 5215, a 5 u strip inside the gutter wall near (548, -1105) that no player hull fits on. Existing areas keep their ids. Re-analyzed in game (same graph, fresh visibility).
The engine hull audit run for the review fixes also lists level links blocked on every lane in both directions. Where the blocker is static and bots do not cross: - Delete five areas no player hull fits in: beside the clothing racks near (1966, -760), beside the paper screen near (1788, -616), on the blockade's edge near (-338, 641), and on the winged car near (1912, -2238), whose wing sits 4 u over its roof. - Cut twelve links across the bollards at x 0 and x 412, which bots walk round and never cross in 56 test matches. Add a 25 x 28 u area in the doorway at (462, -2830) and mark it PRECISE. The link it replaces spanned the wall, and bots leaving the room cut the corner into the wall beside the door: the map's largest stuck spot in the test matches. Links blocked by movable props are kept. Existing areas keep their ids. Re-analyzed in game (same graph, fresh visibility).
This was referenced Oct 3, 2026
sunmachine
approved these changes
Oct 14, 2026
sunmachine
left a comment
There was a problem hiding this comment.
Ballistrade had no obvious issues. Approving.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

ntre_ballistrade_ctg: navmesh rework
One file,
neo/maps/nav/ntre_ballistrade_ctg.nav.Dependencies and status
Needs (worse than master, or broken, without it):
NAV_MESH_AVOIDmarks. Its 7NAV_MESH_PRECISEareas use the movement rules of Bots follow their path on NAV_MESH_PRECISE areas neo#2168 (merged).Helped by (measured better with it; the mesh does not wait on it):
PRECISE+CLIFFfall edges it cuts falls further than #2168 alone (its "Evidence").Pending before review:
At a glance
Four commits:
1. What changed
CNavArea::UpdateBlockedfinds a solid (mostly a prop) at the center of 11 of master's areas on every restart. The path cost then refuses them for the whole round, so bots plan routes they cannot take. They are cut around the obstacle or dropped.2. Id alignment
928 of the 933 areas carry the id of the master area they match. Kept ids that sit more than 64 u from their master location drop from 68 to 12, and an id-keyed diff shows 5 added / 382 removed areas. Geometry, connections, attributes and the analysis data are unchanged by this step.
3-4. Review fixes
An outside review of this PR found eight walk links between areas at the same height that ran one way only: an earlier pass that cut links a player hull cannot cross judged each direction on its own. Each pair was swept in both directions with the engine's hull audit (a player hull moved along the link in the server, recording the props and brushes it hits). Commit 3:
Also in commit 3, from the structural check run for this review (not in the review): four climbs of 34-48 u had lost their way back down, onto wall tops near (772, -40), (1302, -2095) and (1940, -1132) and a crouch nook near (488, 962). A drop is always possible where a climb is, so the drops are restored, as on master. A fifth such wall-top strip near (548, -1105), 5 u wide and inside the gutter wall, has no room for a player hull and is deleted.
Beyond the review (commit 4). The engine hull audit of commit 3's mesh (a player hull also stood every 4 u on every area) lists links blocked on every lane in both directions and areas no hull fits in. Each was checked against whether bots crossed it or stood in it in the test matches below, and the stuck events near it.
PRECISElike the doorway 4109 in section 1, takes the link's place: 2 events in 1 of 28 matches.Kept: 11 pairs blocked by props that move during a round (the motorcycle near (800, -2600), which bots crossed 148 times in 56 matches; office chairs, recycle bins, the signage stands, a cardboard box) or by a breakable window near (1938, -862) (45 crossings). Those are left to the bots at run time.
Existing areas keep their ids; the doorway is a new area. Re-analyzed in game after each commit.
How it was tested
Reachability:
Master against this mesh, same bot code, one batch. Byte-identical copies of the map, one carrying each
.nav. CTG with the ghost pinned at each of the 7 ghost spawns, 3 matches each, 30 bots, default weapon damage. The count excludes stuck events in the spawn crush at round start and the weapon-scavenging behavior.FAIL_NO_PATH_EXISTSmove failures 7.2 -> 5.4 a matchBots still see and shoot across the mesh. 89 % of kills are between bots in different nav areas and 73 % in non-adjacent ones, against 93 % / 76 % on master, at a similar kill distance (median 278 u against 283 u).
Commits 3-4 against commits 1-2 (2026-10-02), on upstream master + #2176 + #2186 with logging, the same design (each of the 7 ghost spawns pinned, 30 bots, default weapon damage, 8 matches at a time). Every match reached match end with 0 asserts and no crash (140 matches).
FAIL_NO_PATH_EXISTS5.7 -> 7.0 a match; kills 40.7 -> 40.9; ghost captures 35 -> 36 of 56 rounds; no fall deaths; 91 % of kills between bots in different nav areas (92 % before)How the pinned-ghost probes work
The offline checks show that the mesh links an area to a spawn. They do not show that a bot will walk there: a link can cross a gap the player hull cannot fit through, or lead along a route path planning never picks. To test one area in game, the area is made the objective and bots are sent to get it.
sv_neo_ghost_spawn_pos "x y z". It replaces the position the round's chosen ghost spawn would have used, so any point becomes the CTG objective. The ghost is dropped a little above the area and settles onto it as it would from a real spawn. The map file is not edited..navby map name, so the harness copies the.bspbyte for byte under a second name (for examplentre_oilstainb_ctg) that loads its own.nav. The same pin then runs on both meshes in one batch. The copy only carries the second mesh; the ghost comes from the cvar.On this map. The five raised tops linked in this PR were probed on a byte-identical copy, 6 runs each, with a control picked up 6/6. Four were picked up 6/6, mostly from the floor below, so the probe says little about the climb itself; the fifth was 0/6 and is removed. Earlier screens on older revisions got pickups at the largest floor region removed from master's mesh (4/4) and at four areas no bot had visited.