set g_lms 0 "Last Man Standing: everyone starts with a certain amount of lives, and the survivor wins"
set g_lms_lives_override -1
set g_lms_extra_lives 0
-set g_lms_regenerate 0
+set g_lms_regenerate 0 "health and/or armor regeneration, according to g_balance_health_regen and g_balance_armor_regen"
+set g_lms_rot 0 "health and/or armor rotting, according to g_balance_health_rot and g_balance_armor_rot"
set g_lms_last_join 3 "if g_lms_join_anytime is 0, new players can only join if the worst active player has (fraglimit - g_lms_last_join) or more lives; in other words, new players can no longer join once the worst player loses more than g_lms_last_join lives"
set g_lms_join_anytime 1 "1: new players can join, but get same amount of lives as the worst player; 0: new players can only join if the worst active player has (fraglimit - g_lms_last_join) or more lives"
set g_lms_items 0 "enables items to spawn, weaponarena still disables weapons and ammo (to force all items to spawn, use g_pickup_items 1 instead)"
int autocvar_g_lms_last_join;
bool autocvar_g_lms_items;
bool autocvar_g_lms_regenerate;
+bool autocvar_g_lms_rot;
// main functions
int LMS_NewPlayerLives()
MUTATOR_HOOKFUNCTION(lms, PlayerRegen)
{
- if(autocvar_g_lms_regenerate)
- return false;
- return true;
+ if(!autocvar_g_lms_regenerate)
+ M_ARGV(2, float) = 0;
+ if(!autocvar_g_lms_rot)
+ M_ARGV(3, float) = 0;
+ return (!autocvar_g_lms_regenerate && !autocvar_g_lms_rot);
}
MUTATOR_HOOKFUNCTION(lms, ForbidThrowCurrentWeapon)