Skip to content

Enhanced bot improvements & Minor fixes#93

Merged
alcachofass merged 8 commits into
alcachofass:mainfrom
br33zy59:main
May 25, 2026
Merged

Enhanced bot improvements & Minor fixes#93
alcachofass merged 8 commits into
alcachofass:mainfrom
br33zy59:main

Conversation

@br33zy59

Copy link
Copy Markdown
Contributor

Minor fixes:

  • Test for OGG support before loading main menu OGG background music track.
  • Rename & reformat background track to be more compatible, strip metadata, crush from ~8 to ~1Mb.
  • Add Cursor-specific instructions under /.cursor/ that defines how clankers should perform builds.
  • Fixed bots (all, not just enhanced) getting stuck in a loop riding a jump-pad repeatedly.

Changes to Enhanced Bots (bot_enhanced 1 only):

  • Refactor to support ai_enhanced_move alongside ai_enhanced_aim. Stripped most of the new rocket jump logic out of dmq3.c and into ai_bot_move_harness and ai_bot_move_util
  • Bots now ignore ammo boxes for guns they don't have or when they already have plenty
  • Bots now aim to hit their target's feet when wielding the rocket launcher, not center mass
  • Bots will switch away from RL if their opponent has the higher ground
  • Bots will use SG or PG in close-quarters combat in preference over the gauntlet
  • Bots seek health items as priority when health is low
  • Removed grappling hook from list of desirable weapons, it's kinda half in the game in some maps and so bots waste time seeking to an item that's not really there.
  • Changed railgun shot behaviour so bots will aim ahead with railgun and fire when target passes their crosshair (skill scaled)
  • With slow fire weapons (RG, RL, SG) if we are on-target but haven't fired for a while, it becomes increasingly urgent to get a shot off.
  • Bots will now more effectively move on from targeting an opponent once they're dead. Previous ways of testing this weren't robust.
  • Bots were dropping down ledges during item seeks, then getting timed out trying to climb back up and resume their travel. Now ledge drops are avoided if not essential
  • Bots will check for likely fall damage if they are about to drop off a ledge, and avoid doing if it their health is low.

br33zy59 and others added 8 commits May 21, 2026 22:45
The main menu background music wasn't playing in Quake3e. Threw a warning about wrong sample rate (44khz, should be 22khz). I'm guessing ioQuake3 is more tolerant.
Resampled via ffmpeg and stripped metadata from file. Reduced from 8Mb to 2Mb file size.
Also took the opportunity to rename and move file from \sound\misc\ to \music\ and shorten name.
Also tweaked the 'is ogg supported on this engine' test and wrapped it around the menu BG music.
There's a duplicated test function in ui_menu and cg_main.

Bugfix: Main menu not working

Bugfix: New player model loading
Joining player models weren't being loaded on join or scoreboard open, regardless of cg_deferPlayers value.
Expected behaviour: New player's model and sounds are loaded when they join the game (if cg_deferPlayers 0) or when the scoreboard is next shown (if cg_deferPlayers 1).
Pre-fix behavior: New player's model and sounds only loaded at map change or vid_restart
Root cause: We were accidentally loading the cg_teamColor value into the model loading path, because we instantiated a temporary variable 'v' and re-used it incorrectly during the parse routine. When the game got to the part where it loaded the model, it would always fail, because the model name was wrong.
Attempts to get rocket jumping working with the new bot_enhanced system had infested ai_dm13.c with code that didn't belong there. Refactored it out to ai_bot_move_harness.c/h
Then fixed up rocket jumps so they (mostly) work under the new system.

Further refactor bot_enhanced_move

Moved a lot of stuff out to a util for later re-use
Extant bug in standard bot code - Bots would sometimes ride a jump pad, then immediately drop down and ride it again, repeating infinitely until another player came along to spoil their bouncy-castle funtime.
This was happening because jumppad rides aren't explicitly recognised during a bot's usual A-B travel where traversed segments are popped from the stack. This change detects jumppad rides and moves the journey forward, blocking a repeat of the same ride.

At least, in theory. Works on my test machine ;)

Also a minor addition: Standing orders for Cursor agent

My lovely coding agent occasionally forgets how to build the project when I refresh the context and it loses the thread on our conversations. By placing this file, Cursor (mine, or anyones) should (SHOULD) reference this as part of it's context every time it operates on the repo.
Numerous tweaks to:
- Goal acquisition
- Bots aiming ahead of target when target is moving
- Bots aiming at feet when wielding rocket launcher, not trying to hit center mass
- Also fix some crazy whitespace in items code (Thanks Cursor).
- Bots seek health items as priority when health is low
- Removed grappling hook from list of desirable weapons, it's kinda half in the game in some maps and so bots waste time seeking to an item that's not really there.
- Changed railgun shot behaviour so bots will aim ahead with railgun and fire when target passes their crosshair (skill scaled)
- With slow fire weapons (RG, RL, SG) if we are on-target but haven't fired for a while, it becomes increasingly urgent to get a shot off.
- Bots will now more effectively move on from targeting an opponent once they're dead. Previous ways of testing this weren't robust.
- Bots will check for likely fall damage if they are about to drop off a ledge, and avoid doing if it their health is low.
Added Shotgun and Plasma rifle as close-combat options for a bot, not just a gauntlet charge.
- Bots were dropping down ledges during item seeks, then getting timed out trying to climb back up and resume their travel. Now ledge drops are avoided if not essential
- Shifted relevant bot_enhanced functionality (rocket jump, ledge drop damage) under bot_enhanced_movement gate CVAR
@alcachofass alcachofass merged commit 735ae5e into alcachofass:main May 25, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants