]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - host_cmd.c
Cleaned up reflection and refraction a bit; added Q3 shader parameters dp_reflect...
[xonotic/darkplaces.git] / host_cmd.c
index 463fb7293bd971699ec8ce0fe4d70eac42f15708..21c8690ab492e94af922be38f158dbb85dd6dd04 100644 (file)
@@ -19,6 +19,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 */
 
 #include "quakedef.h"
+#include "sv_demo.h"
 
 int current_skill;
 cvar_t sv_cheats = {0, "sv_cheats", "0", "enables cheat commands in any game, and cheat impulses in dpmod"};
@@ -568,7 +569,7 @@ void Host_Loadgame_f (void)
        }
 
        // version
-       COM_ParseToken_Simple(&t, false);
+       COM_ParseToken_Simple(&t, false, false);
        version = atoi(com_token);
        if (version != SAVEGAME_VERSION)
        {
@@ -578,25 +579,25 @@ void Host_Loadgame_f (void)
        }
 
        // description
-       COM_ParseToken_Simple(&t, false);
+       COM_ParseToken_Simple(&t, false, false);
 
        for (i = 0;i < NUM_SPAWN_PARMS;i++)
        {
-               COM_ParseToken_Simple(&t, false);
+               COM_ParseToken_Simple(&t, false, false);
                spawn_parms[i] = atof(com_token);
        }
        // skill
-       COM_ParseToken_Simple(&t, false);
+       COM_ParseToken_Simple(&t, false, false);
 // this silliness is so we can load 1.06 save files, which have float skill values
        current_skill = (int)(atof(com_token) + 0.5);
        Cvar_SetValue ("skill", (float)current_skill);
 
        // mapname
-       COM_ParseToken_Simple(&t, false);
+       COM_ParseToken_Simple(&t, false, false);
        strlcpy (mapname, com_token, sizeof(mapname));
 
        // time
-       COM_ParseToken_Simple(&t, false);
+       COM_ParseToken_Simple(&t, false, false);
        time = atof(com_token);
 
        allowcheats = sv_cheats.integer != 0;
@@ -617,7 +618,7 @@ void Host_Loadgame_f (void)
        {
                // light style
                oldt = t;
-               COM_ParseToken_Simple(&t, false);
+               COM_ParseToken_Simple(&t, false, false);
                // if this is a 64 lightstyle savegame produced by Quake, stop now
                // we have to check this because darkplaces saves 256 lightstyle savegames
                if (com_token[0] == '{')
@@ -635,7 +636,7 @@ void Host_Loadgame_f (void)
        for(;;)
        {
                oldt = t;
-               COM_ParseToken_Simple(&t, false);
+               COM_ParseToken_Simple(&t, false, false);
                if (com_token[0] == '{')
                {
                        t = oldt;
@@ -650,10 +651,10 @@ void Host_Loadgame_f (void)
        for (;;)
        {
                start = t;
-               while (COM_ParseToken_Simple(&t, false))
+               while (COM_ParseToken_Simple(&t, false, false))
                        if (!strcmp(com_token, "}"))
                                break;
-               if (!COM_ParseToken_Simple(&start, false))
+               if (!COM_ParseToken_Simple(&start, false, false))
                {
                        // end of file
                        break;
@@ -808,6 +809,7 @@ void Host_Name_f (void)
                MSG_WriteByte (&sv.reliable_datagram, svc_updatename);
                MSG_WriteByte (&sv.reliable_datagram, host_client - svs.clients);
                MSG_WriteString (&sv.reliable_datagram, host_client->name);
+               SV_WriteNetnameIntoDemo(host_client);
        }
 }
 
@@ -1583,7 +1585,7 @@ void Host_Kick_f (void)
                if (Cmd_Argc() > 2)
                {
                        message = Cmd_Args();
-                       COM_ParseToken_Simple(&message, false);
+                       COM_ParseToken_Simple(&message, false, false);
                        if (byNumber)
                        {
                                message++;                                                      // skip the #