diff --git a/quakespasm/Quake/host.c b/quakespasm/Quake/host.c index 8271a3fe..e02a54e5 100644 --- a/quakespasm/Quake/host.c +++ b/quakespasm/Quake/host.c @@ -44,11 +44,12 @@ double host_frametime; double host_time; double realtime; // without any filtering or bounding double oldrealtime; // last frame run -int host_framecount; -int host_hunklevel; +int host_framecount; -int minimum_memory; +int host_hunklevel; + +int minimum_memory; client_t *host_client; // current client @@ -70,8 +71,8 @@ cvar_t timelimit = {"timelimit","0",false,true}; cvar_t teamplay = {"teamplay","0",false,true}; cvar_t samelevel = {"samelevel","0"}; cvar_t noexit = {"noexit","0",false,true}; -cvar_t skill = {"skill","1"}; // 0 - 3 -cvar_t deathmatch = {"deathmatch","0"}; // 0, 1, or 2 +cvar_t skill = {"skill","1"}; // 0 - 3 +cvar_t deathmatch = {"deathmatch","0"}; // 0, 1, or 2 cvar_t coop = {"coop","0"}; // 0 or 1 cvar_t pausable = {"pausable","1"}; @@ -90,12 +91,11 @@ overflowtimes_t dev_overflows; //this stores the last time overflow messages wer Max_Edicts_f -- johnfitz ================ */ -void Max_Edicts_f (void) +static void Max_Edicts_f (void) { static float oldval = DEF_EDICTS; //must match the default value for max_edicts //TODO: clamp it here? - if (max_edicts.value == oldval) return; @@ -105,6 +105,19 @@ void Max_Edicts_f (void) oldval = max_edicts.value; } +// 1999-09-06 deathmatch/coop not at the same time fix by Maddes +static void Callback_Deathmatch (void) +{ + if (deathmatch.value) + Cvar_Set ("coop", "0"); +} + +static void Callback_Coop (void) +{ + if (coop.value) + Cvar_Set ("deathmatch", "0"); +} + /* ================ Host_EndGame @@ -261,8 +274,8 @@ void Host_InitLocal (void) Cvar_RegisterVariable (&noexit, NULL); Cvar_RegisterVariable (&skill, NULL); Cvar_RegisterVariable (&developer, NULL); - Cvar_RegisterVariable (&deathmatch, NULL); - Cvar_RegisterVariable (&coop, NULL); + Cvar_RegisterVariable (&coop, Callback_Coop); + Cvar_RegisterVariable (&deathmatch, Callback_Deathmatch); Cvar_RegisterVariable (&pausable, NULL); diff --git a/quakespasm/Quake/net_main.c b/quakespasm/Quake/net_main.c index e636134c..247391c2 100644 --- a/quakespasm/Quake/net_main.c +++ b/quakespasm/Quake/net_main.c @@ -210,10 +210,14 @@ static void MaxPlayers_f (void) if (n == 1) { Cvar_Set ("deathmatch", "0"); + Cvar_Set ("coop", "0"); } else { - Cvar_Set ("deathmatch", "1"); + if (coop.value) + Cvar_Set ("deathmatch", "0"); + else + Cvar_Set ("deathmatch", "1"); } } diff --git a/quakespasm/README.html b/quakespasm/README.html index 3d98b154..45699cfa 100644 --- a/quakespasm/README.html +++ b/quakespasm/README.html @@ -11,7 +11,7 @@
 

-

QuakeSpasm 0.85.5 (20 December 2011)

+

QuakeSpasm 0.85.5 (25 December 2011)

1. About

@@ -160,7 +160,7 @@ Compile time options include

diff --git a/quakespasm/README.sgml b/quakespasm/README.sgml index 02b04ac5..36cda89e 100644 --- a/quakespasm/README.sgml +++ b/quakespasm/README.sgml @@ -4,7 +4,7 @@ -QuakeSpasm 0.85.5 (20 December 2011) +QuakeSpasm 0.85.5 (25 December 2011) About

@@ -94,7 +94,7 @@ Alternatively, have a look at Makefile.darwin for more instructions on SDL input driver updated adding native keymap and dead key support to the console Fixed a crash in net play in maps with extended limits - Verified successful compilation using gcc-4.6 + Verified successful compilation using gcc-4.6.x Added a cvar gl_zfix to stop GL texture flicker (z fighting) Read video variables early so that a vid_restart isn't necessary after init mlook and lookspring fixes @@ -102,6 +102,7 @@ Alternatively, have a look at Makefile.darwin for more instructions on Made mp3 playback to allocate system memory instead of zone Some updates to the progs interpreter code Fixed r_nolerp_list parsing code from fitzquake + Made sure that deathmatch and coop are not set at the same time Several code updates from uHexen2, several code cleanups.

diff --git a/quakespasm/README.txt b/quakespasm/README.txt index 0ebbb184..3617e563 100644 --- a/quakespasm/README.txt +++ b/quakespasm/README.txt @@ -29,7 +29,7 @@ ______________________________________________________________________ - QuakeSpasm 0.85.5 (20 December 2011) + QuakeSpasm 0.85.5 (25 December 2011) 1. About @@ -161,7 +161,7 @@ o Fixed a crash in net play in maps with extended limits - o Verified successful compilation using gcc-4.6 + o Verified successful compilation using gcc-4.6.x o Added a cvar gl_zfix to stop GL texture flicker (z fighting) @@ -179,6 +179,8 @@ o Fixed r_nolerp_list parsing code from fitzquake + o Made sure that deathmatch and coop are not set at the same time + o Several code updates from uHexen2, several code cleanups. 5.2. Changes in 0.85.4