Skip to content

feat(perf): cache convar, engine autobunnyhopping#21

Merged
Rushaway merged 3 commits intomainfrom
Rushaway-patch-2
Mar 17, 2026
Merged

feat(perf): cache convar, engine autobunnyhopping#21
Rushaway merged 3 commits intomainfrom
Rushaway-patch-2

Conversation

@Rushaway
Copy link
Member

  • This change aim performance by replacing OnPlayerRunCmd with sv_autobunnyhopping
  • Caching convar values used multiples time
  • Do not unload plugins (Antibhopcheat automaticly detect sv_autobunnyhopping changes)

Copilot AI review requested due to automatic review settings March 17, 2026 16:40
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the map-specific SourceMod plugin to reduce per-tick overhead by removing the OnPlayerRunCmd auto-bhop implementation in favor of engine convars, and by caching frequently-read convar values.

Changes:

  • Replace the OnPlayerRunCmd bunnyhop logic with toggling sv_autobunnyhopping and sv_airaccelerate during race mode.
  • Cache sm_makovote_rtd and sm_makovote_cd_maxstages values and keep them updated via convar change hooks.
  • Stop unloading/reloading AntiBhopCheat and adminmenu when toggling race bhop.

Added functionality to store and restore auto-bhop settings during race mode.
@Rushaway Rushaway merged commit 5a68265 into main Mar 17, 2026
6 checks passed
@Rushaway Rushaway deleted the Rushaway-patch-2 branch March 17, 2026 17:08
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