How to get bots to recognize elevators? Also, player-testing?

peefTube

L1: Registered
Jul 10, 2020
7
0
I know this isn't something most people deal with and it's unconventional for TF2 maps, but I've designated a couple elevators so players can reach critical strategic positions in a more convenient manner, as opposed to running through thin corridors trying to find a ramp to get to a strong sniper/sentry location.

Now, for players the function of these elevators should be quite easy to catch onto, but for bots, the navmesh refuses to recognize them. One of the sets of elevators (this is a mirrored map, it's KOTH) is near floor-level so bots have had 50/50 success with that set, but one specific set of elevators is raised above ground level, connected by a staircase, and bots refuse to acknowledge it as the navmesh refuses to acknowledge it.

Is there any way to create a workaround or am I just stuck? I could try playerclipping the edge of the elevator with some sort of nav_prefer brush on top of that to see if it changes anything... but if anyone has any better ideas then I'm all ears. Otherwise, I'll just have to deal with the bots not really recognizing the change, which I'll be a little bit disappointed about, but there's not much I can really do about that.

I do need to do player testing but I'm not sure how I would do that, either. I know there's a way to set up a TF2 server but I've tried following instructions I've seen and it never gets me anywhere, so if anyone knows how to do that it would be much appreciated!

Thanks in advance!
 

Cincomma

bonk sploosh
aa
Aug 2, 2017
430
404
Regarding playtesting, we have a Discord server where we hang out and announce impromptu playtests. You can pop in and throw your map into the bot and it'll be tested when it's on the top of the list. During playtests the server is commonly full, so you don't have to worry about small playercounts unless it's on the tailend of a test, in that case, re-upload the map to the bot and it'll be played again with more players the next map test.
 

Tiftid

the Embodiment of Scarlet Devil
aa
Sep 10, 2016
518
391
I don't want to be that guy, but jump pads are usually a superior situation to elevators, and would be easier to use with bots, since you could just use nav_connect to form a two-way connection between the navmeshes on the jump pad and the navmeshes on the floor above it.

In terms of what you have already, I simply can't imagine how a navmesh wouldn't be formed on an elevator if there's a staircase leading up to it, unless nav_generate doesn't place navmesh areas on func_doors or func_movelinears, which might be a reasonable thing for it to do. In that case, you can use nav_begin_area on one corner of the elevator, drag a square to the other corner and use nav_end_area to make a nav square in the elevator - however, you then need to manually connect it to the stairs. Also, if the elevators require a button press to activate, I don't think you'll have any way of making bots activate them.
 

peefTube

L1: Registered
Jul 10, 2020
7
0
Okay, so nav_edit WILL recognize the surface of the func_door as a surface, I take it? If so then that definitely solves a lot of my problems, I just have to probably make those segments of the navmesh transient and do the two-way connection you mentioned
 

henke37

aa
Sep 23, 2011
2,075
515
You can craft entire nav areas manually. No requirements that the level geometry matches.
 

mintoyatsu

L1: Registered
Mar 24, 2019
14
7
In Open Fortress, I created a floating stack of nav areas with one-way connections all the way to the top. This made bots wait on the elevator until it stopped. I think the distance between nav areas is important or else bots will prefer a shorter path, so the amount you'll need varies depending on how far your elevator travels. It also helps to have a wall up against the elevator so you can actually create floating nav areas, otherwise the nav editor will just snap to the ground.

The downside to this method is that if the elevator has already left, bots will wait at the bottom until they get crushed. Maybe a func_door to block the area would help that, but I don't know.