Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bot behaviors do not work with some combinations of cvars #2968

Open
sweet235 opened this issue Apr 4, 2024 · 2 comments
Open

Bot behaviors do not work with some combinations of cvars #2968

sweet235 opened this issue Apr 4, 2024 · 2 comments
Labels
A-Bots T-Bug T-Question for questions on how things works on on how to proceed on an issue

Comments

@sweet235
Copy link
Contributor

sweet235 commented Apr 4, 2024

A bug I invented can be seen on the juggernaut server. That server has set g_disabledEquipment ckit.

If a server does that, but has set g_bot_buildHumans on, one assumption I made in the bot build behavior is invalid. I assumed that it would always be possible for a bot to suicide and spawn as a builder (as long as there are spawns). The effect is to put one human bot in an endless suicide loop.

Now I wonder how to fix that. This particular case would be easy to handle by adding a way to query g_disabledEquipment in the behavior tree language. But do we want that? These files are already rather difficult to test.

Please help me answer these questions:

  • Are there other combinations of cvars that make default.bt fail in a similar way?
  • How should we handle such cvar conflicts? (Ignore, and comment? Handle them in the behavior tree language? Something else?)
@slipher
Copy link
Contributor

slipher commented Apr 4, 2024

Disabling the ckit is not really compatible with standard gameplay, so I feel this is not a case bot developers should have to deal with. The juggernaut mod has a completely different gameplay objective so its author should provide an appropriate BT instead of relying on default ones.

The default BTs should gracefully handle settings that only slightly tweak the gameplay e.g. disabling Lucifer Cannon.

Now I wonder how to fix that. This particular case would be easy to handle by adding a way to query g_disabledEquipment in the behavior tree language.

In general we should probably have APIs for testing if a weapon/upgrade/etc. is available, combining disabled equipment/g_bot_ cvars, and unlock status. I believe this exists in C++ but is not yet exposed for BT.

@slipher
Copy link
Contributor

slipher commented Apr 6, 2024

On the other hand we should handle g_bot_ckit being disabled. So if we did that using an API for equipment availability, then the case of ckit being disabled for everyone would be covered too.

@slipher slipher added A-Bots T-Bug T-Question for questions on how things works on on how to proceed on an issue labels Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Bots T-Bug T-Question for questions on how things works on on how to proceed on an issue
Projects
None yet
Development

No branches or pull requests

2 participants