From d4f27c04bdd086f40ce1d32b75d8eba56b68e0f9 Mon Sep 17 00:00:00 2001 From: Mario Date: Tue, 15 Jun 2021 13:16:24 +0000 Subject: [PATCH] Consolidates a few of the networked stats to free up some slots. Also removes an old special command feature. --- qcsrc/client/view.qc | 70 ------------------- qcsrc/common/gamemodes/gamemode/ctf/cl_ctf.qc | 2 +- qcsrc/common/gamemodes/gamemode/ctf/sv_ctf.qc | 22 ++---- .../gamemode/keepaway/cl_keepaway.qc | 3 +- .../gamemodes/gamemode/keepaway/keepaway.qh | 4 ++ .../gamemode/keepaway/sv_keepaway.qc | 6 +- .../gamemodes/gamemode/keyhunt/cl_keyhunt.qc | 2 +- .../gamemodes/gamemode/keyhunt/sv_keyhunt.qc | 13 +--- .../gamemodes/gamemode/nexball/cl_nexball.qc | 18 ++--- .../gamemodes/gamemode/nexball/nexball.qh | 4 ++ .../gamemodes/gamemode/nexball/sv_nexball.qc | 4 +- .../mutators/mutator/bugrigs/bugrigs.qc | 22 ++++++ qcsrc/common/physics/player.qc | 2 - qcsrc/common/stats.qh | 13 ++-- qcsrc/common/weapons/weapon/vaporizer.qc | 2 +- qcsrc/common/weapons/weapon/vortex.qc | 2 +- qcsrc/server/player.qc | 2 - xonotic-server.cfg | 2 - 18 files changed, 60 insertions(+), 133 deletions(-) diff --git a/qcsrc/client/view.qc b/qcsrc/client/view.qc index 1a01662d1..389afebfe 100644 --- a/qcsrc/client/view.qc +++ b/qcsrc/client/view.qc @@ -855,75 +855,6 @@ void HitSound() } } -const int MAX_SPECIALCOMMAND = 15; -vector specialcommand_slots[MAX_SPECIALCOMMAND]; -vector specialcommand_colors[MAX_SPECIALCOMMAND]; -const float SPECIALCOMMAND_SPEED = 150; -const float SPECIALCOMMAND_TURNSPEED = 2; -const float SPECIALCOMMAND_SIZE = 0.025; -const float SPECIALCOMMAND_CHANCE = 0.35; -float sc_spawntime, sc_changetime; -vector sc_color = '1 1 1'; -void SpecialCommand() -{ - if(!STAT(MOVEVARS_SPECIALCOMMAND)) - return; - - if(time >= sc_changetime) - { - sc_changetime = time + 1; - sc_color = randomvec() * 1.5; - sc_color.x = bound(0.2, sc_color.x, 0.75); - sc_color.y = bound(0.2, sc_color.y, 0.75); - sc_color.z = bound(0.2, sc_color.z, 0.75); - } - drawfill('0 0 0', vec2(vid_conwidth, vid_conheight), sc_color, autocvar_hud_colorflash_alpha * bound(0.1, sc_changetime - time, 0.3), DRAWFLAG_ADDITIVE); - - if(!precache_pic("gfx/smile")) - return; // damn party poopers - - for(int j = MAX_SPECIALCOMMAND - 1; j >= 0; --j) - { - vector slot = specialcommand_slots[j]; - if(slot.y) - slot.y += SPECIALCOMMAND_SPEED * frametime; - //if(slot.z) - //slot.z = sin(SPECIALCOMMAND_TURNSPEED * M_PI * time); - if(slot.y >= vid_conheight) - slot = '0 0 0'; - - if(slot == '0 0 0') - { - if(random() <= SPECIALCOMMAND_CHANCE && time > sc_spawntime) // low chance to spawn! - { - slot.x = bound(0, (random() * vid_conwidth + 1), vid_conwidth); - slot.y = 1; // start it off 0 so we can use it - slot.z = floor(random() * REGISTRY_COUNT(Weapons)); - sc_spawntime = time + bound(0.4, random(), 0.75); // prevent spawning another one for this amount of time! - vector newcolor = randomvec() * 2; - newcolor.x = bound(0.4, newcolor.x, 1); - newcolor.y = bound(0.4, newcolor.y, 1); - newcolor.z = bound(0.4, newcolor.z, 1); - specialcommand_colors[j] = newcolor; - } - } - else - { - vector splash_size = '0 0 0'; - splash_size.x = max(vid_conwidth, vid_conheight) * SPECIALCOMMAND_SIZE; - splash_size.y = max(vid_conwidth, vid_conheight) * SPECIALCOMMAND_SIZE; - entity wep = REGISTRY_GET(Weapons, slot.z); - if(wep == WEP_Null) - drawpic(vec2(slot), "gfx/smile", vec2(splash_size), specialcommand_colors[j], 0.95, DRAWFLAG_NORMAL); - else - drawpic_skin(vec2(slot), wep.model2, vec2(splash_size), specialcommand_colors[j], 0.95, DRAWFLAG_NORMAL); - //drawrotpic(vec2(slot), slot.z, "gfx/smile", vec2(splash_size), vec2(splash_size) / 2, specialcommand_colors[j], 0.95, DRAWFLAG_NORMAL); - } - - specialcommand_slots[j] = slot; - } -} - void HUD_Draw(entity this) { // if we don't know gametype and scores yet avoid drawing the scoreboard @@ -981,7 +912,6 @@ void HUD_Draw(entity this) } // crosshair goes VERY LAST - SpecialCommand(); UpdateDamage(); HUD_Crosshair(this); HitSound(); diff --git a/qcsrc/common/gamemodes/gamemode/ctf/cl_ctf.qc b/qcsrc/common/gamemodes/gamemode/ctf/cl_ctf.qc index dc49c605c..f5bf2e364 100644 --- a/qcsrc/common/gamemodes/gamemode/ctf/cl_ctf.qc +++ b/qcsrc/common/gamemodes/gamemode/ctf/cl_ctf.qc @@ -28,7 +28,7 @@ void HUD_Mod_CTF(vector pos, vector mySize) float redflag_statuschange_elapsedtime = 0, blueflag_statuschange_elapsedtime = 0, yellowflag_statuschange_elapsedtime = 0, pinkflag_statuschange_elapsedtime = 0, neutralflag_statuschange_elapsedtime = 0; // time since the status changed bool ctf_oneflag; // one-flag CTF mode enabled/disabled bool ctf_stalemate; // currently in stalemate - int stat_items = STAT(CTF_FLAGSTATUS); + int stat_items = STAT(OBJECTIVE_STATUS); float fs, fs2, fs3, size1, size2; vector e1, e2; diff --git a/qcsrc/common/gamemodes/gamemode/ctf/sv_ctf.qc b/qcsrc/common/gamemodes/gamemode/ctf/sv_ctf.qc index 904d26e8f..5323d1f03 100644 --- a/qcsrc/common/gamemodes/gamemode/ctf/sv_ctf.qc +++ b/qcsrc/common/gamemodes/gamemode/ctf/sv_ctf.qc @@ -2159,7 +2159,7 @@ MUTATOR_HOOKFUNCTION(ctf, PlayerPreThink) bool b1 = false, b2 = false, b3 = false, b4 = false, b5 = false; // TODO: kill this, we WANT to show the other flags, somehow! (note: also means you don't see if you're FC) // initially clear items so they can be set as necessary later. - STAT(CTF_FLAGSTATUS, player) &= ~(CTF_RED_FLAG_CARRYING | CTF_RED_FLAG_TAKEN | CTF_RED_FLAG_LOST + STAT(OBJECTIVE_STATUS, player) &= ~(CTF_RED_FLAG_CARRYING | CTF_RED_FLAG_TAKEN | CTF_RED_FLAG_LOST | CTF_BLUE_FLAG_CARRYING | CTF_BLUE_FLAG_TAKEN | CTF_BLUE_FLAG_LOST | CTF_YELLOW_FLAG_CARRYING | CTF_YELLOW_FLAG_TAKEN | CTF_YELLOW_FLAG_LOST | CTF_PINK_FLAG_CARRYING | CTF_PINK_FLAG_TAKEN | CTF_PINK_FLAG_LOST @@ -2173,7 +2173,7 @@ MUTATOR_HOOKFUNCTION(ctf, PlayerPreThink) if(flag.team == NUM_TEAM_2 && !b2) { b2 = true; t = CTF_BLUE_FLAG_CARRYING; t2 = CTF_BLUE_FLAG_TAKEN; t3 = CTF_BLUE_FLAG_LOST; } if(flag.team == NUM_TEAM_3 && !b3) { b3 = true; t = CTF_YELLOW_FLAG_CARRYING; t2 = CTF_YELLOW_FLAG_TAKEN; t3 = CTF_YELLOW_FLAG_LOST; } if(flag.team == NUM_TEAM_4 && !b4) { b4 = true; t = CTF_PINK_FLAG_CARRYING; t2 = CTF_PINK_FLAG_TAKEN; t3 = CTF_PINK_FLAG_LOST; } - if(flag.team == 0 && !b5) { b5 = true; t = CTF_NEUTRAL_FLAG_CARRYING; t2 = CTF_NEUTRAL_FLAG_TAKEN; t3 = CTF_NEUTRAL_FLAG_LOST; STAT(CTF_FLAGSTATUS, player) |= CTF_FLAG_NEUTRAL; } + if(flag.team == 0 && !b5) { b5 = true; t = CTF_NEUTRAL_FLAG_CARRYING; t2 = CTF_NEUTRAL_FLAG_TAKEN; t3 = CTF_NEUTRAL_FLAG_LOST; STAT(OBJECTIVE_STATUS, player) |= CTF_FLAG_NEUTRAL; } switch(flag.ctf_status) { @@ -2181,14 +2181,14 @@ MUTATOR_HOOKFUNCTION(ctf, PlayerPreThink) case FLAG_CARRY: { if((flag.owner == player) || (flag.pass_sender == player)) - STAT(CTF_FLAGSTATUS, player) |= t; // carrying: player is currently carrying the flag + STAT(OBJECTIVE_STATUS, player) |= t; // carrying: player is currently carrying the flag else - STAT(CTF_FLAGSTATUS, player) |= t2; // taken: someone else is carrying the flag + STAT(OBJECTIVE_STATUS, player) |= t2; // taken: someone else is carrying the flag break; } case FLAG_DROPPED: { - STAT(CTF_FLAGSTATUS, player) |= t3; // lost: the flag is dropped somewhere on the map + STAT(OBJECTIVE_STATUS, player) |= t3; // lost: the flag is dropped somewhere on the map break; } } @@ -2196,10 +2196,10 @@ MUTATOR_HOOKFUNCTION(ctf, PlayerPreThink) // item for stopping players from capturing the flag too often if(player.ctf_captureshielded) - STAT(CTF_FLAGSTATUS, player) |= CTF_SHIELDED; + STAT(OBJECTIVE_STATUS, player) |= CTF_SHIELDED; if(ctf_stalemate) - STAT(CTF_FLAGSTATUS, player) |= CTF_STALEMATE; + STAT(OBJECTIVE_STATUS, player) |= CTF_STALEMATE; // update the health of the flag carrier waypointsprite if(player.wps_flagcarrier) @@ -2526,14 +2526,6 @@ MUTATOR_HOOKFUNCTION(ctf, TeamBalance_CheckAllowedTeams) M_ARGV(1, string) = "ctf_team"; } -MUTATOR_HOOKFUNCTION(ctf, SpectateCopy) -{ - entity spectatee = M_ARGV(0, entity); - entity client = M_ARGV(1, entity); - - STAT(CTF_FLAGSTATUS, client) = STAT(CTF_FLAGSTATUS, spectatee); -} - MUTATOR_HOOKFUNCTION(ctf, GetRecords) { int record_page = M_ARGV(0, int); diff --git a/qcsrc/common/gamemodes/gamemode/keepaway/cl_keepaway.qc b/qcsrc/common/gamemodes/gamemode/keepaway/cl_keepaway.qc index 7ac6225f1..a643ff2dc 100644 --- a/qcsrc/common/gamemodes/gamemode/keepaway/cl_keepaway.qc +++ b/qcsrc/common/gamemodes/gamemode/keepaway/cl_keepaway.qc @@ -16,8 +16,7 @@ void HUD_Mod_Keepaway(vector pos, vector mySize) float kaball_alpha = blink(0.85, 0.15, 5); - int stat_items = STAT(ITEMS); - int kaball = (stat_items/IT_KEY1) & 1; + int kaball = (STAT(OBJECTIVE_STATUS) & KA_CARRYING); if(kaball != kaball_prevstatus) { diff --git a/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qh b/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qh index cf21ab0d3..3aac451d1 100644 --- a/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qh +++ b/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qh @@ -19,3 +19,7 @@ CLASS(Keepaway, Gametype) #endif ENDCLASS(Keepaway) REGISTER_GAMETYPE(KEEPAWAY, NEW(Keepaway)); + +#ifdef GAMEQC +const int KA_CARRYING = BIT(0); +#endif diff --git a/qcsrc/common/gamemodes/gamemode/keepaway/sv_keepaway.qc b/qcsrc/common/gamemodes/gamemode/keepaway/sv_keepaway.qc index 6952f3138..013123bb0 100644 --- a/qcsrc/common/gamemodes/gamemode/keepaway/sv_keepaway.qc +++ b/qcsrc/common/gamemodes/gamemode/keepaway/sv_keepaway.qc @@ -387,12 +387,8 @@ MUTATOR_HOOKFUNCTION(ka, PlayerPreThink) { entity player = M_ARGV(0, entity); - // clear the item used for the ball in keepaway - player.items &= ~IT_KEY1; - // if the player has the ball, make sure they have the item for it (Used for HUD primarily) - if(player.ballcarried) - player.items |= IT_KEY1; + STAT(OBJECTIVE_STATUS, player) = BITSET(STAT(OBJECTIVE_STATUS, player), KA_CARRYING, player.ballcarried != NULL); } MUTATOR_HOOKFUNCTION(ka, PlayerUseKey) diff --git a/qcsrc/common/gamemodes/gamemode/keyhunt/cl_keyhunt.qc b/qcsrc/common/gamemodes/gamemode/keyhunt/cl_keyhunt.qc index e95275eba..29cb4194a 100644 --- a/qcsrc/common/gamemodes/gamemode/keyhunt/cl_keyhunt.qc +++ b/qcsrc/common/gamemodes/gamemode/keyhunt/cl_keyhunt.qc @@ -10,7 +10,7 @@ void HUD_Mod_KH(vector pos, vector mySize) mod_active = 1; // keyhunt should never hide the mod icons panel // Read current state - int state = STAT(KH_KEYS); + int state = STAT(OBJECTIVE_STATUS); if(!state) return; int i, key_state; diff --git a/qcsrc/common/gamemodes/gamemode/keyhunt/sv_keyhunt.qc b/qcsrc/common/gamemodes/gamemode/keyhunt/sv_keyhunt.qc index baa42536d..5f90c390f 100644 --- a/qcsrc/common/gamemodes/gamemode/keyhunt/sv_keyhunt.qc +++ b/qcsrc/common/gamemodes/gamemode/keyhunt/sv_keyhunt.qc @@ -131,12 +131,12 @@ void kh_update_state() s |= (32 ** key.count) * f; } - FOREACH_CLIENT(true, { STAT(KH_KEYS, it) = s; }); + FOREACH_CLIENT(true, { STAT(OBJECTIVE_STATUS, it) = s; }); FOR_EACH_KH_KEY(key) { if(key.owner) - STAT(KH_KEYS, key.owner) |= (32 ** key.count) * 31; + STAT(OBJECTIVE_STATUS, key.owner) |= (32 ** key.count) * 31; } //print(ftos((nextent(NULL)).kh_state), "\n"); } @@ -724,7 +724,6 @@ void kh_Key_Spawn(entity initial_owner, float _angle, float i) // runs every ti settouch(key, kh_Key_Touch); setthink(key, kh_Key_Think); key.nextthink = time; - key.items = IT_KEY1 | IT_KEY2; key.cnt = _angle; key.angles = '0 360 0' * random(); key.event_damage = kh_Key_Damage; @@ -1261,14 +1260,6 @@ MUTATOR_HOOKFUNCTION(kh, TeamBalance_CheckAllowedTeams, CBC_ORDER_EXCLUSIVE) return true; } -MUTATOR_HOOKFUNCTION(kh, SpectateCopy) -{ - entity spectatee = M_ARGV(0, entity); - entity client = M_ARGV(1, entity); - - STAT(KH_KEYS, client) = STAT(KH_KEYS, spectatee); -} - MUTATOR_HOOKFUNCTION(kh, PlayerUseKey) { entity player = M_ARGV(0, entity); diff --git a/qcsrc/common/gamemodes/gamemode/nexball/cl_nexball.qc b/qcsrc/common/gamemodes/gamemode/nexball/cl_nexball.qc index fa7be6e50..935232cdf 100644 --- a/qcsrc/common/gamemodes/gamemode/nexball/cl_nexball.qc +++ b/qcsrc/common/gamemodes/gamemode/nexball/cl_nexball.qc @@ -6,30 +6,24 @@ // Nexball HUD mod icon void HUD_Mod_NexBall(vector pos, vector mySize) { - float nb_pb_starttime, dt, p; - int stat_items; + int stat_items = STAT(OBJECTIVE_STATUS); + float nb_pb_starttime = STAT(NB_METERSTART); - stat_items = STAT(ITEMS); - nb_pb_starttime = STAT(NB_METERSTART); - - if (stat_items & IT_KEY1) - mod_active = 1; - else - mod_active = 0; + mod_active = (stat_items & NB_CARRYING); //Manage the progress bar if any if (nb_pb_starttime > 0) { - dt = (time - nb_pb_starttime) % nb_pb_period; + float dt = (time - nb_pb_starttime) % nb_pb_period; // one period of positive triangle - p = 2 * dt / nb_pb_period; + float p = 2 * dt / nb_pb_period; if (p > 1) p = 2 - p; HUD_Panel_DrawProgressBar(pos, mySize, "progressbar", p, (mySize.x <= mySize.y), 0, autocvar_hud_progressbar_nexball_color, autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL); } - if (stat_items & IT_KEY1) + if (stat_items & NB_CARRYING) drawpic_aspect_skin(pos, "nexball_carrying", eX * mySize.x + eY * mySize.y, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL); } diff --git a/qcsrc/common/gamemodes/gamemode/nexball/nexball.qh b/qcsrc/common/gamemodes/gamemode/nexball/nexball.qh index a8fdaa4ef..96f310611 100644 --- a/qcsrc/common/gamemodes/gamemode/nexball/nexball.qh +++ b/qcsrc/common/gamemodes/gamemode/nexball/nexball.qh @@ -31,3 +31,7 @@ CLASS(NexBall, Gametype) ENDCLASS(NexBall) REGISTER_GAMETYPE(NEXBALL, NEW(NexBall)); #define g_nexball IS_GAMETYPE(NEXBALL) + +#ifdef GAMEQC +const int NB_CARRYING = BIT(0); +#endif diff --git a/qcsrc/common/gamemodes/gamemode/nexball/sv_nexball.qc b/qcsrc/common/gamemodes/gamemode/nexball/sv_nexball.qc index c0cce8e15..5fed894b9 100644 --- a/qcsrc/common/gamemodes/gamemode/nexball/sv_nexball.qc +++ b/qcsrc/common/gamemodes/gamemode/nexball/sv_nexball.qc @@ -94,7 +94,7 @@ void ball_restart(entity this) void nexball_setstatus(entity this) { - this.items &= ~IT_KEY1; + STAT(OBJECTIVE_STATUS, this) &= ~NB_CARRYING; if(this.ballcarried) { if(this.ballcarried.lifetime && (this.ballcarried.lifetime < time)) @@ -105,7 +105,7 @@ void nexball_setstatus(entity this) ResetBall(e); } else - this.items |= IT_KEY1; + STAT(OBJECTIVE_STATUS, this) |= NB_CARRYING; } } diff --git a/qcsrc/common/mutators/mutator/bugrigs/bugrigs.qc b/qcsrc/common/mutators/mutator/bugrigs/bugrigs.qc index 38a687f01..1ee60e1d4 100644 --- a/qcsrc/common/mutators/mutator/bugrigs/bugrigs.qc +++ b/qcsrc/common/mutators/mutator/bugrigs/bugrigs.qc @@ -1,5 +1,7 @@ #include "bugrigs.qh" +#ifdef SVQC // NOTE: disabled on the client side until prediction can be fixed! + #ifdef GAMEQC #ifdef SVQC @@ -24,6 +26,7 @@ REGISTER_MUTATOR(bugrigs, true); #endif +#if 0 #define PHYS_BUGRIGS(s) STAT(BUGRIGS, s) #define PHYS_BUGRIGS_ACCEL(s) STAT(BUGRIGS_ACCEL, s) #define PHYS_BUGRIGS_AIR_STEERING(s) STAT(BUGRIGS_AIR_STEERING, s) @@ -39,6 +42,23 @@ REGISTER_MUTATOR(bugrigs, true); #define PHYS_BUGRIGS_SPEED_POW(s) STAT(BUGRIGS_SPEED_POW, s) #define PHYS_BUGRIGS_SPEED_REF(s) STAT(BUGRIGS_SPEED_REF, s) #define PHYS_BUGRIGS_STEER(s) STAT(BUGRIGS_STEER, s) +#else +#define PHYS_BUGRIGS(s) g_bugrigs +#define PHYS_BUGRIGS_ACCEL(s) g_bugrigs_accel +#define PHYS_BUGRIGS_AIR_STEERING(s) g_bugrigs_air_steering +#define PHYS_BUGRIGS_ANGLE_SMOOTHING(s) g_bugrigs_angle_smoothing +#define PHYS_BUGRIGS_CAR_JUMPING(s) g_bugrigs_planar_movement_car_jumping +#define PHYS_BUGRIGS_FRICTION_AIR(s) g_bugrigs_friction_air +#define PHYS_BUGRIGS_FRICTION_BRAKE(s) g_bugrigs_friction_brake +#define PHYS_BUGRIGS_FRICTION_FLOOR(s) g_bugrigs_friction_floor +#define PHYS_BUGRIGS_PLANAR_MOVEMENT(s) g_bugrigs_planar_movement +#define PHYS_BUGRIGS_REVERSE_SPEEDING(s) g_bugrigs_reverse_speeding +#define PHYS_BUGRIGS_REVERSE_SPINNING(s) g_bugrigs_reverse_spinning +#define PHYS_BUGRIGS_REVERSE_STOPPING(s) g_bugrigs_reverse_stopping +#define PHYS_BUGRIGS_SPEED_POW(s) g_bugrigs_speed_pow +#define PHYS_BUGRIGS_SPEED_REF(s) g_bugrigs_speed_ref +#define PHYS_BUGRIGS_STEER(s) g_bugrigs_steer +#endif #if defined(SVQC) @@ -336,3 +356,5 @@ MUTATOR_HOOKFUNCTION(bugrigs, BuildMutatorsPrettyString) #endif #endif + +#endif diff --git a/qcsrc/common/physics/player.qc b/qcsrc/common/physics/player.qc index f4e2d912c..d562ab64b 100644 --- a/qcsrc/common/physics/player.qc +++ b/qcsrc/common/physics/player.qc @@ -518,8 +518,6 @@ void SpecialCommand(entity this) if (!CheatImpulse(this, CHIMPULSE_GIVE_ALL.impulse)) LOG_INFO("A hollow voice says \"Plugh\"."); } - else - STAT(MOVEVARS_SPECIALCOMMAND, this) = true; } #endif diff --git a/qcsrc/common/stats.qh b/qcsrc/common/stats.qh index e5621c29e..1d96dacde 100644 --- a/qcsrc/common/stats.qh +++ b/qcsrc/common/stats.qh @@ -66,14 +66,17 @@ REGISTER_STAT(PL_CROUCH_MIN, vector) REGISTER_STAT(PL_MAX, vector) REGISTER_STAT(PL_CROUCH_MAX, vector) -REGISTER_STAT(KH_KEYS, int) +// networked bitflag for game objective display (modicons) +REGISTER_STAT(OBJECTIVE_STATUS, int) +#ifdef SVQC +SPECTATE_COPYFIELD(_STAT(OBJECTIVE_STATUS)) +#endif #ifdef SVQC float W_WeaponRateFactor(entity this); float game_stopped; float game_starttime; //point in time when the countdown to game start is over float round_starttime; //point in time when the countdown to round start is over -bool autocvar_g_allow_oldvortexbeam; int autocvar_leadlimit; // TODO: world.qh can't be included here due to circular includes! #define autocvar_fraglimit cvar("fraglimit") @@ -88,8 +91,6 @@ REGISTER_STAT(STRENGTH_FINISHED, float) REGISTER_STAT(INVINCIBLE_FINISHED, float) /** arc heat in [0,1] */ REGISTER_STAT(PRESSED_KEYS, int) -/** this stat could later contain some other bits of info, like, more server-side particle config */ -REGISTER_STAT(ALLOW_OLDVORTEXBEAM, bool, autocvar_g_allow_oldvortexbeam) REGISTER_STAT(FUEL, int) REGISTER_STAT(NB_METERSTART, float) /** compressShotOrigin */ @@ -130,7 +131,6 @@ REGISTER_STAT(FROZEN, int) REGISTER_STAT(REVIVE_PROGRESS, float) REGISTER_STAT(ROUNDLOST, int) REGISTER_STAT(BUFF_TIME, float) -REGISTER_STAT(CTF_FLAGSTATUS, int) REGISTER_STAT(CAPTURE_PROGRESS, float) REGISTER_STAT(ENTRAP_ORB, float) REGISTER_STAT(ENTRAP_ORB_ALPHA, float) @@ -184,6 +184,7 @@ float g_bugrigs_speed_ref; float g_bugrigs_speed_pow; float g_bugrigs_steer; #endif +#if 0 REGISTER_STAT(BUGRIGS, int, g_bugrigs) REGISTER_STAT(BUGRIGS_ACCEL, float, g_bugrigs_accel) REGISTER_STAT(BUGRIGS_AIR_STEERING, int, g_bugrigs_air_steering) @@ -199,6 +200,7 @@ REGISTER_STAT(BUGRIGS_REVERSE_STOPPING, int, g_bugrigs_reverse_stopping) REGISTER_STAT(BUGRIGS_SPEED_POW, float, g_bugrigs_speed_pow) REGISTER_STAT(BUGRIGS_SPEED_REF, float, g_bugrigs_speed_ref) REGISTER_STAT(BUGRIGS_STEER, float, g_bugrigs_steer) +#endif #ifdef SVQC int autocvar_sv_gameplayfix_downtracesupportsongroundflag = 1; @@ -424,7 +426,6 @@ REGISTER_STAT(MOVEVARS_MAXAIRSPEED, float) REGISTER_STAT(MOVEVARS_STEPHEIGHT, float, autocvar_sv_stepheight) REGISTER_STAT(MOVEVARS_AIRACCEL_QW, float) REGISTER_STAT(MOVEVARS_AIRACCEL_SIDEWAYS_FRICTION, float) -REGISTER_STAT(MOVEVARS_SPECIALCOMMAND, bool) #ifdef SVQC int autocvar_sv_wallclip; #endif diff --git a/qcsrc/common/weapons/weapon/vaporizer.qc b/qcsrc/common/weapons/weapon/vaporizer.qc index 6f4d4aebf..2a0dd7cef 100644 --- a/qcsrc/common/weapons/weapon/vaporizer.qc +++ b/qcsrc/common/weapons/weapon/vaporizer.qc @@ -62,7 +62,7 @@ void VaporizerBeam_Draw(entity this) Draw_VaporizerBeam_trace_callback_tex = string_null; /*if(!MUTATOR_CALLHOOK(Particles_VaporizerBeam, this.vorg1, this.vorg2)) - if(autocvar_cl_particles_oldvortexbeam && (STAT(ALLOW_OLDVORTEXBEAM) || isdemo())) + if(autocvar_cl_particles_oldvortexbeam) WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM_OLD), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE); else WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);*/ diff --git a/qcsrc/common/weapons/weapon/vortex.qc b/qcsrc/common/weapons/weapon/vortex.qc index 7372fe8e1..5ba28f9c7 100644 --- a/qcsrc/common/weapons/weapon/vortex.qc +++ b/qcsrc/common/weapons/weapon/vortex.qc @@ -63,7 +63,7 @@ NET_HANDLE(TE_CSQC_VORTEXBEAMPARTICLE, bool isNew) if(!MUTATOR_CALLHOOK(Particles_VortexBeam, shotorg, endpos)) { - if(autocvar_cl_particles_oldvortexbeam && (STAT(ALLOW_OLDVORTEXBEAM) || isdemo())) + if(autocvar_cl_particles_oldvortexbeam) WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM_OLD), shotorg, endpos, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE); else WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM), shotorg, endpos, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE); diff --git a/qcsrc/server/player.qc b/qcsrc/server/player.qc index 1d83be8d1..dd0007e36 100644 --- a/qcsrc/server/player.qc +++ b/qcsrc/server/player.qc @@ -563,8 +563,6 @@ void PlayerDamage(entity this, entity inflictor, entity attacker, float damage, STAT(SUPERWEAPONS_FINISHED, this) = 0; STAT(AIR_FINISHED, this) = 0; - STAT(MOVEVARS_SPECIALCOMMAND, this) = false; // sweet release - this.death_time = time; if (random() < 0.5) animdecide_setstate(this, this.anim_state | ANIMSTATE_DEAD1, true); diff --git a/xonotic-server.cfg b/xonotic-server.cfg index be57248ac..09cb0e856 100644 --- a/xonotic-server.cfg +++ b/xonotic-server.cfg @@ -49,8 +49,6 @@ set sv_timeout_number 2 "how many timeouts one player is allowed to call (gets r set sv_timeout_leadtime 4 "how long the players will be informed that a timeout was called before it starts, in seconds" set sv_timeout_resumetime 3 "how long the remaining timeout-time will be after a player called the timein command" -set g_allow_oldvortexbeam 1 "If enabled, clients are allowed to use old v2.3 Vortex beam" - set g_telefrags 1 "telefragging, i.e. killing someone who stands in the way of someone who is teleporting" set g_telefrags_teamplay 1 "never telefrag team mates" set g_telefrags_avoid 1 "when teleporters have a random destination, avoid teleporting to locations where a telefrag would happen" -- 2.39.2