shithub: choc

Download patch

ref: aedc1c2d8c8eecfc609b291b9fe2983e03a744fe
parent: a802be4c5cb24fba9baadd17fc6bd9a27108c8d1
author: Simon Howard <[email protected]>
date: Thu Jan 24 14:09:47 EST 2008

Fix fast / respawning monsters parameter not exchanged when starting
netgames (thanks GhostlyDeath).

Subversion-branch: /trunk/chocolate-doom
Subversion-revision: 1014

--- a/src/net_client.c
+++ b/src/net_client.c
@@ -387,6 +387,8 @@
     settings.loadgame = startloadgame;
     settings.gameversion = gameversion;
     settings.nomonsters = nomonsters;
+    settings.fast_monsters = fastparm;
+    settings.respawn_monsters = respawnparm;
     settings.timelimit = timelimit;
 
     //!
@@ -685,6 +687,8 @@
     startloadgame = settings.loadgame;
     lowres_turn = settings.lowres_turn;
     nomonsters = settings.nomonsters;
+    fastparm = settings.fast_monsters;
+    respawnparm = settings.respawn_monsters;
     net_cl_new_sync = settings.new_sync != 0;
     timelimit = settings.timelimit;
 
--- a/src/net_defs.h
+++ b/src/net_defs.h
@@ -120,6 +120,8 @@
     int deathmatch;
     int episode;
     int nomonsters;
+    int fast_monsters;
+    int respawn_monsters;
     int map;
     int skill;
     int gameversion;
--- a/src/net_structrw.c
+++ b/src/net_structrw.c
@@ -35,6 +35,8 @@
     NET_WriteInt8(packet, settings->extratics);
     NET_WriteInt8(packet, settings->deathmatch);
     NET_WriteInt8(packet, settings->nomonsters);
+    NET_WriteInt8(packet, settings->fast_monsters);
+    NET_WriteInt8(packet, settings->respawn_monsters);
     NET_WriteInt8(packet, settings->episode);
     NET_WriteInt8(packet, settings->map);
     NET_WriteInt8(packet, settings->skill);
@@ -51,6 +53,8 @@
         && NET_ReadInt8(packet, (unsigned int *) &settings->extratics)
         && NET_ReadInt8(packet, (unsigned int *) &settings->deathmatch)
         && NET_ReadInt8(packet, (unsigned int *) &settings->nomonsters)
+        && NET_ReadInt8(packet, (unsigned int *) &settings->fast_monsters)
+        && NET_ReadInt8(packet, (unsigned int *) &settings->respawn_monsters)
         && NET_ReadInt8(packet, (unsigned int *) &settings->episode)
         && NET_ReadInt8(packet, (unsigned int *) &settings->map)
         && NET_ReadSInt8(packet, &settings->skill)