rtxa / agmodx

AG Mod X is an improved Mini AG alternative made as a plugin for AMX Mod X from the ground. It's easy to add new stuff, make improvements, do changes, etc.
GNU General Public License v3.0
22 stars 9 forks source link

Make mp_respawn_fix 1 a bit faster #31

Closed gundogfan closed 1 week ago

gundogfan commented 1 year ago

I got some complaints about this command on my sv. When disabled obviosuly those with high FPS will respawn just too fast, but when enabled it's even worse, it's too slow.

With mp_respawn_fix 1 respawning takes almost 2 seconds while fps_max 125 takes 1.2 seconds approx. It may not be a big difference (less than a second) but especially for Crossfire players it's insanely slow, at high level it's impossible to stop the respawn killing spree if it takes you almost 2 seconds to go back in track and kill the one controlling the map.

Is it possible to pair it with the respawning time of 125fps? or even better, 250fps. Not saying 500 cause yeah it'll be too much.

rtxa commented 1 year ago

Well, I did set the value according to players who play at 125fps, which is 0.95 seconds. The calculation of that value takes into consideration the old behaviour which expect 120 frames from the player to be able to spawn, which means:

You can modify the mp_respawn_fix delay value if you don't feel comfortable with mp_respawn_delay CVar.

Original code involved:

https://github.com/ValveSoftware/halflife/blob/c7240b965743a53a29491dd49320c88eecf6257b/dlls/player.cpp#L1295-L1297

Hope this clarifies a little bit what this does.

gundogfan commented 1 year ago

mp_respawn_delay doesn't seem to work, it's as if the cvar didn't exist.

L 03/06/2023 - 04:05:48: [admincmd.amxx] Cmd: "HL1 ARGENTINA #3 (TDM/Arena)<0><><>" set cvar (name "mp_respawn_fix") (value "1") [AMXX] Cvar "mp_respawn_fix" changed to "1" [AMXX] Unknown cvar: mp_respawn_delay