diff --git a/engine/client/cl_main.c b/engine/client/cl_main.c index 4e2c9315..48b47a7b 100644 --- a/engine/client/cl_main.c +++ b/engine/client/cl_main.c @@ -6867,7 +6867,7 @@ void CL_ArgumentOverrides(void) //note that this does NOT include commandline. void CL_ExecInitialConfigs(char *resetcommand) { -#ifdef QUAKESTATS +#ifndef QUAKETC int qrc, hrc; #endif int def; diff --git a/engine/client/view.c b/engine/client/view.c index 6eb3ee01..2db9d3ab 100644 --- a/engine/client/view.c +++ b/engine/client/view.c @@ -1948,6 +1948,7 @@ static void SCR_DrawAutoID(vec3_t org, player_info_t *pl, qboolean isteam) break; if (r >= 0 && (scr_autoid_weapon_mask.ival&(1<<1))) { +#ifdef QUAKEHUD if (scr_autoid_weapon.ival==1) { extern apic_t *sb_weapons[7][8]; @@ -1970,6 +1971,7 @@ static void SCR_DrawAutoID(vec3_t org, player_info_t *pl, qboolean isteam) return; } } +#endif if (h < 8) { diff --git a/engine/common/bothdefs.h b/engine/common/bothdefs.h index 728cc74b..21564c3a 100644 --- a/engine/common/bothdefs.h +++ b/engine/common/bothdefs.h @@ -1107,7 +1107,7 @@ STAT_MOVEVARS_AIRACCEL_SIDEWAYS_FRICTION = 255, // DP MAX_CL_STATS = 256 }; -#ifdef QUAKEHUD +#ifdef QUAKESTATS // // item flags // diff --git a/engine/server/pr_cmds.c b/engine/server/pr_cmds.c index e150ab41..77be9443 100644 --- a/engine/server/pr_cmds.c +++ b/engine/server/pr_cmds.c @@ -371,9 +371,11 @@ pbool PDECL ED_CanFree (edict_t *ed) static void ASMCALL StateOp (pubprogfuncs_t *prinst, float var, func_t func) { stdentvars_t *vars = PROG_TO_EDICT(prinst, pr_global_struct->self)->v; +#ifdef HEXEN2 if (progstype == PROG_H2) vars->nextthink = pr_global_struct->time+0.05; else +#endif vars->nextthink = pr_global_struct->time+0.1; vars->think = func; vars->frame = var; @@ -1163,7 +1165,7 @@ void PR_LoadGlabalStruct(qboolean muted) buttonfields[i].offset = -1; } -#ifdef HEXEN2 +#if defined(HEXEN2) && defined(QUAKESTATS) /*Hexen2 has lots of extra stats, which I don't want special support for, so list them here and send them as for csqc*/ if (progstype == PROG_H2) { diff --git a/engine/server/progdefs.h b/engine/server/progdefs.h index 072f8170..2301e2aa 100644 --- a/engine/server/progdefs.h +++ b/engine/server/progdefs.h @@ -153,6 +153,13 @@ typedef struct nqglobalvars_s #define comfieldfloatdep_legacy comfieldfloatdep #endif +#ifndef QUAKESTATS +#define comfieldfloat_legacystat(n,desc) +#define comfieldfloatdep_legacystat(n,desc,depreason) +#else +#define comfieldfloat_legacystat comfieldfloat +#define comfieldfloatdep_legacystat comfieldfloatdep +#endif /*my hands are tied when it comes to the layout of this structure On the server side, the structure *must* match original quakeworld, or we break compatibility with mvdsv's qvm api @@ -339,8 +346,8 @@ and the extension fields are added on the end and can have extra vm-specific stu comfieldfloat(SendFlags,"Indicates that something in the entity has been changed, and that it needs to be updated to all players that can see it. The engine will clear it at some point, with the cleared bits appearing in the 'changedflags' argument of the SendEntity method.")/*EXT_CSQC_1 (one of the DP guys came up with it)*/\ comfieldfloatdep_legacy(Version,"Obsolete", "Use SendFlags instead.")/*EXT_CSQC (obsolete)*/\ comfieldfloatdep_legacy(clientcolors,NULL, "Doesn't support RGB player colours.")\ - comfieldfloat_legacy(viewzoom,NULL)/*DP_VIEWZOOM, stats*/\ - comfieldfloat_legacy(items2,"stub. commented by default, to prevent items2 being networked instead of runes.") /*added in quake 1.09 (for hipnotic). legacy because of stats*/\ + comfieldfloat_legacystat(viewzoom,NULL)/*DP_VIEWZOOM, stats*/\ + comfieldfloat_legacystat(items2,"stub. commented by default, to prevent items2 being networked instead of runes.") /*added in quake 1.09 (for hipnotic). legacy because of stats*/\ svextqcfieldshexen2 \ comfieldfloat(pvsflags,"Reconfigures when the entity is visible to clients")/*EXT_CSQC_1*/\ comfieldfloat(uniquespawnid,"Incremented by 1 whenever the entity is respawned. Persists across remove calls, for when the two-second grace period is insufficient.")/*FTE_ENT_UNIQUESPAWNID*/\ diff --git a/engine/server/server.h b/engine/server/server.h index 2f56cf7e..a381b108 100644 --- a/engine/server/server.h +++ b/engine/server/server.h @@ -232,7 +232,9 @@ typedef struct server_s qboolean gamedirchanged; +#ifdef QUAKESTATS qboolean haveitems2; //use items2 field instead of serverflags for the high bits of STAT_ITEMS +#endif diff --git a/engine/server/sv_ents.c b/engine/server/sv_ents.c index b8aa7a0e..67e1467b 100644 --- a/engine/server/sv_ents.c +++ b/engine/server/sv_ents.c @@ -2937,11 +2937,13 @@ void SV_WritePlayersToClient (client_t *client, client_frame_t *frame, edict_t * clst.onground = (int)ent->v->flags & FL_ONGROUND; clst.solid = ent->v->solid && ent->v->solid != SOLID_CORPSE && ent->v->solid != SOLID_TRIGGER; +#ifdef HEXEN2 if (progstype == PROG_H2 && ((int)vent->v->effects & H2EF_NODRAW)) { clst.effects = 0; clst.modelindex = 0; } +#endif clst.skin = vent->v->skin; clst.mins = vent->v->mins;