]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
Eliminate a few client-only files from the dedicated build
authorcloudwalk <cloudwalk@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 5 Oct 2020 18:03:45 +0000 (18:03 +0000)
committercloudwalk <cloudwalk@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 5 Oct 2020 18:03:45 +0000 (18:03 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12995 d7cf8633-e32d-0410-b094-e92efae38249

cl_parse.c
makefile.inc

index 4f1a07e2ac4bfa606a778918c7daab0e9fff68c0..379c6ec6efed807426e4caecdebb026754fb2162 100644 (file)
@@ -3703,7 +3703,9 @@ void CL_ParseServerMessage(void)
                                        for (i = 1;i < cl.maxclients;i++)
                                                cl.entities_active[i] = false;
                                }
+#ifndef SERVERONLY
                                EntityStateQW_ReadPlayerUpdate();
+#endif
                                break;
 
                        case qw_svc_nails:
@@ -3726,7 +3728,9 @@ void CL_ParseServerMessage(void)
                                break;
 
                        case qw_svc_packetentities:
+#ifndef SERVERONLY
                                EntityFrameQW_CL_ReadFrame(false);
+#endif
                                // first update is the final signon stage
                                if (cls.signon == SIGNONS - 1)
                                {
@@ -3736,7 +3740,9 @@ void CL_ParseServerMessage(void)
                                break;
 
                        case qw_svc_deltapacketentities:
+#ifndef SERVERONLY
                                EntityFrameQW_CL_ReadFrame(true);
+#endif
                                // first update is the final signon stage
                                if (cls.signon == SIGNONS - 1)
                                {
@@ -3807,7 +3813,9 @@ void CL_ParseServerMessage(void)
                                        cls.signon = SIGNONS;
                                        CL_SignonReply ();
                                }
+#ifndef SERVERONLY
                                EntityFrameQuake_ReadEntity (cmd&127);
+#endif
                                continue;
                        }
 
@@ -4208,12 +4216,14 @@ void CL_ParseServerMessage(void)
                                        cls.signon = SIGNONS;
                                        CL_SignonReply ();
                                }
+#ifndef SERVERONLY
                                if (cls.protocol == PROTOCOL_DARKPLACES1 || cls.protocol == PROTOCOL_DARKPLACES2 || cls.protocol == PROTOCOL_DARKPLACES3)
                                        EntityFrame_CL_ReadFrame();
                                else if (cls.protocol == PROTOCOL_DARKPLACES4)
                                        EntityFrame4_CL_ReadFrame();
                                else
                                        EntityFrame5_CL_ReadFrame();
+#endif
                                break;
                        case svc_csqcentities:
                                CSQC_ReadEntities();
@@ -4238,8 +4248,9 @@ void CL_ParseServerMessage(void)
        if (cls.signon == SIGNONS)
                CL_UpdateItemsAndWeapon();
 //     R_TimeReport("UpdateItems");
-
+#ifndef SERVERONLY
        EntityFrameQuake_ISeeDeadEntities();
+#endif
 //     R_TimeReport("ISeeDeadEntities");
 
        CL_UpdateMoveVars();
index 2fdc966a2d3c1c612d6b5b6deba187e40f165965..bdf7b8089697cf7c5b455d8ad8f8cb3cb138f395 100644 (file)
@@ -82,11 +82,6 @@ OBJ_COMMON= \
        cl_cmd.o \
        cl_collision.o \
        cl_demo.o \
-       cl_ents.o \
-       cl_ents4.o \
-       cl_ents5.o \
-       cl_ents_nq.o \
-       cl_ents_qw.o \
        cl_input.o \
        cl_main.o \
        cl_parse.o \
@@ -176,6 +171,13 @@ OBJ_COMMON= \
        world.o \
        zone.o
 
+OBJ_CL= \
+       cl_ents.o \
+       cl_ents4.o \
+       cl_ents5.o \
+       cl_ents_qw.o \
+       cl_ents_nq.o
+
 OBJ_MENU= \
        menu.o \
        mvm_cmds.o
@@ -202,7 +204,7 @@ endif
 
 CFLAGS_COMMON=$(CFLAGS_STANDARD) $(CFLAGS_TCC) $(CFLAGS_MAKEDEP) $(CFLAGS_PRELOAD) $(CFLAGS_FS) $(CFLAGS_WARNINGS) $(CFLAGS_LIBZ) $(CFLAGS_LIBJPEG) $(CFLAGS_SND_XMP) $(CFLAGS_NET) $(CFLAGS_SDL) -D_FILE_OFFSET_BITS=64 -D__KERNEL_STRICT_NAMES -I../../../
 CFLAGS_CLIENT=-DCONFIG_MENU $(CFLAGS_VIDEO_CAPTURE)
-CFLAGS_SERVER=
+CFLAGS_SERVER=-DSERVERONLY
 CFLAGS_DEBUG=-ggdb
 CFLAGS_PROFILE=-g -pg -ggdb -fprofile-arcs
 CFLAGS_RELEASE=
@@ -503,7 +505,7 @@ $(EXE_SV): $(OBJ_SV) $(OBJ_ICON)
        $(CHECKLEVEL2)
        $(DO_LD)
 
-$(EXE_SDL): $(OBJ_SDL) $(OBJ_ICON)
+$(EXE_SDL): $(OBJ_CL) $(OBJ_SDL) $(OBJ_ICON)
        $(CHECKLEVEL2)
        $(DO_LD)
 
@@ -511,7 +513,7 @@ $(EXE_SVNEXUIZ): $(OBJ_SV) $(OBJ_ICON_NEXUIZ)
        $(CHECKLEVEL2)
        $(DO_LD)
 
-$(EXE_SDLNEXUIZ): $(OBJ_SDL) $(OBJ_ICON_NEXUIZ)
+$(EXE_SDLNEXUIZ): $(OBJ_CL) $(OBJ_SDL) $(OBJ_ICON_NEXUIZ)
        $(CHECKLEVEL2)
        $(DO_LD)