]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make it compile without XONOTIC defined
authorMario <mario@smbclan.net>
Sun, 23 Oct 2016 04:26:38 +0000 (14:26 +1000)
committerMario <mario@smbclan.net>
Sun, 23 Oct 2016 04:26:38 +0000 (14:26 +1000)
32 files changed:
qcsrc/Makefile
qcsrc/client/hud/panel/scoreboard.qc
qcsrc/client/progs.inc
qcsrc/client/shownames.qc
qcsrc/client/view.qc
qcsrc/client/weapons/projectile.qc
qcsrc/common/constants.qh
qcsrc/common/net_linked.qh [new file with mode: 0644]
qcsrc/common/notifications/all.qc
qcsrc/common/triggers/target/music.qc
qcsrc/lib/_all.inc
qcsrc/lib/csqcmodel/cl_player.qc
qcsrc/lib/csqcmodel/sv_model.qc
qcsrc/lib/draw.qh
qcsrc/lib/matrix/_mod.inc
qcsrc/lib/matrix/_mod.qh
qcsrc/lib/net.qh
qcsrc/lib/warpzone/server.qc
qcsrc/server/bot/default/bot.qc
qcsrc/server/bot/default/havocbot/havocbot.qc
qcsrc/server/bot/default/navigation.qc
qcsrc/server/bot/default/waypoints.qc
qcsrc/server/command/getreplies.qc
qcsrc/server/command/sv_cmd.qc
qcsrc/server/command/vote.qc
qcsrc/server/progs.inc
qcsrc/server/weapons/accuracy.qc
qcsrc/server/weapons/common.qc
qcsrc/server/weapons/csqcprojectile.qc
qcsrc/server/weapons/selection.qc
qcsrc/server/weapons/tracing.qc
qcsrc/server/weapons/weaponsystem.qc

index 903d8537e695bf35b33fb78889c814a38536cf7b..916fe08c9b52b79d567e3de832366c32e8af14fd 100644 (file)
@@ -7,7 +7,7 @@ WORKDIR ?= ../.tmp
 QCCFLAGS_WATERMARK ?= $(shell git describe --tags --dirty='~')
 VER = $(subst *,\*,$(QCCFLAGS_WATERMARK))
 NDEBUG ?= 1
-XONOTIC ?= 1
+XONOTIC ?= 0
 BUILD_MOD ?=
 
 ifndef ZIP
index 117badbec4e1baf80aca961ff8d22042534d8dd2..ef68e21b2000808fb0a8cec871bb86abda43ea39 100644 (file)
@@ -3,6 +3,7 @@
 #include "quickmenu.qh"
 #include <common/ent_cs.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/minigames/cl_minigames.qh>
 #include <common/stats.qh>
index 327df77c25fd6583f6fe7365bf931f61cc52400d..738831a5d020daf1d093806332ea290c6b8bce79 100644 (file)
@@ -2,9 +2,9 @@
 
 #if XONOTIC
 #include <client/_all.inc>
-#endif
 
 #include <ecs/_mod.inc>
+#endif
 
 #ifdef BUILD_MOD
 #include <mod/client/progs.inc>
index 75ef40521ea443504048bb7669c161db0f671fda..6a4515ac14f128f4b20eba195a090b849a0a138c 100644 (file)
@@ -4,6 +4,7 @@
 
 #include <common/ent_cs.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/teams.qh>
 
index 3134a24ed28fed2c9b917d4d279b31053dee9b46..d309f4d9a757a44feaa13089473b52d2f1986d45 100644 (file)
@@ -13,6 +13,7 @@
 #include <common/ent_cs.qh>
 #include <common/anim.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/debug.qh>
 #include <common/mapinfo.qh>
 #include <common/gamemodes/_mod.qh>
index 6d58ac77a2d1a01f72688513ecc2708750d93622..1f88bc8d60ae01519f0f13774d0f81191e35e279 100644 (file)
@@ -6,6 +6,7 @@
 #include "../mutators/events.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/physics/movetypes/movetypes.qh>
 
 #include <lib/csqcmodel/interpolate.qh>
index 29f96aa4490b527ecab33592689534fb358c16ec..133d0caca3dd123faab0dbbf347cdf19939f6a1a 100644 (file)
@@ -1,60 +1,5 @@
 #pragma once
 
-REGISTER_NET_TEMP(TE_CSQC_PICTURE)
-REGISTER_NET_TEMP(TE_CSQC_RACE)
-REGISTER_NET_TEMP(TE_CSQC_TEAMNAGGER)
-REGISTER_NET_TEMP(TE_CSQC_PINGPLREPORT)
-REGISTER_NET_TEMP(TE_CSQC_WEAPONCOMPLAIN)
-REGISTER_NET_TEMP(TE_CSQC_VEHICLESETUP)
-
-const int RACE_NET_CHECKPOINT_HIT_QUALIFYING = 0; // byte checkpoint, short time, short recordtime, string recordholder
-const int RACE_NET_CHECKPOINT_CLEAR = 1;
-const int RACE_NET_CHECKPOINT_NEXT_QUALIFYING = 2; // byte nextcheckpoint, short recordtime, string recordholder
-const int RACE_NET_CHECKPOINT_HIT_RACE = 3; // byte checkpoint, short delta, byte lapsdelta, string opponent
-const int RACE_NET_CHECKPOINT_HIT_RACE_BY_OPPONENT = 4; // byte checkpoint, short delta, byte lapsdelta, string opponent
-const int RACE_NET_CHECKPOINT_NEXT_SPEC_QUALIFYING = 5; // byte nextcheckpoint, float laptime, short recordtime, string recordholder
-const int RACE_NET_PENALTY_RACE = 6; // byte penaltytime, string reason
-const int RACE_NET_PENALTY_QUALIFYING = 7; // byte penaltytime, string reason
-const int RACE_NET_SERVER_RECORD = 8; // server record, sent to client
-const int RACE_NET_SPEED_AWARD = 9; // speed award, sent to client
-const int RACE_NET_SPEED_AWARD_BEST = 10; // all time best speed award, sent to client
-const int RACE_NET_SERVER_RANKINGS = 11;
-const int RACE_NET_SERVER_STATUS = 12;
-const int RANKINGS_CNT = 15;
-
-REGISTER_NET_LINKED(_ENT_CLIENT_INIT)
-#ifdef CSQC
-NET_HANDLE(_ENT_CLIENT_INIT, bool isnew) { make_pure(this); return true; }
-#endif
-/** Sent as a temp entity from a persistent linked entity */
-REGISTER_NET_TEMP(ENT_CLIENT_INIT)
-
-REGISTER_NET_LINKED(ENT_CLIENT_SCORES_INFO)
-REGISTER_NET_LINKED(ENT_CLIENT_SCORES)
-REGISTER_NET_LINKED(ENT_CLIENT_TEAMSCORES)
-REGISTER_NET_LINKED(ENT_CLIENT_NAGGER) // flags [votecalledvote]
-REGISTER_NET_LINKED(ENT_CLIENT_RADARLINK) // flags [startorigin] [endorigin] [startcolor+16*endcolor]
-REGISTER_NET_LINKED(ENT_CLIENT_PROJECTILE)
-REGISTER_NET_LINKED(ENT_CLIENT_MAPVOTE)
-REGISTER_NET_LINKED(ENT_CLIENT_CLIENTDATA)
-REGISTER_NET_LINKED(ENT_CLIENT_RANDOMSEED)
-REGISTER_NET_LINKED(ENT_CLIENT_ACCURACY)
-REGISTER_NET_LINKED(ENT_CLIENT_ELIMINATEDPLAYERS)
-
-REGISTER_NET_LINKED(ENT_CLIENT_MODEL)
-
-REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE)
-REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE_CAMERA)
-REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE_TELEPORTED)
-
-REGISTER_NET_LINKED(ENT_CLIENT_ARC_BEAM)
-REGISTER_NET_LINKED(ENT_CLIENT_HOOK)
-REGISTER_NET_LINKED(ENT_CLIENT_TUBANOTE)
-
-REGISTER_NET_LINKED(ENT_CLIENT_SPAWNPOINT)
-REGISTER_NET_LINKED(ENT_CLIENT_SPAWNEVENT)
-REGISTER_NET_LINKED(ENT_CLIENT_WALL)
-
 const int SPRITERULE_DEFAULT = 0;
 const int SPRITERULE_TEAMPLAY = 1;
 const int SPRITERULE_SPECTATOR = 2;
diff --git a/qcsrc/common/net_linked.qh b/qcsrc/common/net_linked.qh
new file mode 100644 (file)
index 0000000..a67550a
--- /dev/null
@@ -0,0 +1,56 @@
+#pragma once
+
+REGISTER_NET_TEMP(TE_CSQC_PICTURE)
+REGISTER_NET_TEMP(TE_CSQC_RACE)
+REGISTER_NET_TEMP(TE_CSQC_TEAMNAGGER)
+REGISTER_NET_TEMP(TE_CSQC_PINGPLREPORT)
+REGISTER_NET_TEMP(TE_CSQC_WEAPONCOMPLAIN)
+REGISTER_NET_TEMP(TE_CSQC_VEHICLESETUP)
+
+const int RACE_NET_CHECKPOINT_HIT_QUALIFYING = 0; // byte checkpoint, short time, short recordtime, string recordholder
+const int RACE_NET_CHECKPOINT_CLEAR = 1;
+const int RACE_NET_CHECKPOINT_NEXT_QUALIFYING = 2; // byte nextcheckpoint, short recordtime, string recordholder
+const int RACE_NET_CHECKPOINT_HIT_RACE = 3; // byte checkpoint, short delta, byte lapsdelta, string opponent
+const int RACE_NET_CHECKPOINT_HIT_RACE_BY_OPPONENT = 4; // byte checkpoint, short delta, byte lapsdelta, string opponent
+const int RACE_NET_CHECKPOINT_NEXT_SPEC_QUALIFYING = 5; // byte nextcheckpoint, float laptime, short recordtime, string recordholder
+const int RACE_NET_PENALTY_RACE = 6; // byte penaltytime, string reason
+const int RACE_NET_PENALTY_QUALIFYING = 7; // byte penaltytime, string reason
+const int RACE_NET_SERVER_RECORD = 8; // server record, sent to client
+const int RACE_NET_SPEED_AWARD = 9; // speed award, sent to client
+const int RACE_NET_SPEED_AWARD_BEST = 10; // all time best speed award, sent to client
+const int RACE_NET_SERVER_RANKINGS = 11;
+const int RACE_NET_SERVER_STATUS = 12;
+const int RANKINGS_CNT = 15;
+
+REGISTER_NET_LINKED(_ENT_CLIENT_INIT)
+#ifdef CSQC
+NET_HANDLE(_ENT_CLIENT_INIT, bool isnew) { make_pure(this); return true; }
+#endif
+/** Sent as a temp entity from a persistent linked entity */
+REGISTER_NET_TEMP(ENT_CLIENT_INIT)
+
+REGISTER_NET_LINKED(ENT_CLIENT_SCORES_INFO)
+REGISTER_NET_LINKED(ENT_CLIENT_SCORES)
+REGISTER_NET_LINKED(ENT_CLIENT_TEAMSCORES)
+REGISTER_NET_LINKED(ENT_CLIENT_NAGGER) // flags [votecalledvote]
+REGISTER_NET_LINKED(ENT_CLIENT_RADARLINK) // flags [startorigin] [endorigin] [startcolor+16*endcolor]
+REGISTER_NET_LINKED(ENT_CLIENT_PROJECTILE)
+REGISTER_NET_LINKED(ENT_CLIENT_MAPVOTE)
+REGISTER_NET_LINKED(ENT_CLIENT_CLIENTDATA)
+REGISTER_NET_LINKED(ENT_CLIENT_RANDOMSEED)
+REGISTER_NET_LINKED(ENT_CLIENT_ACCURACY)
+REGISTER_NET_LINKED(ENT_CLIENT_ELIMINATEDPLAYERS)
+
+REGISTER_NET_LINKED(ENT_CLIENT_MODEL)
+
+REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE)
+REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE_CAMERA)
+REGISTER_NET_LINKED(ENT_CLIENT_WARPZONE_TELEPORTED)
+
+REGISTER_NET_LINKED(ENT_CLIENT_ARC_BEAM)
+REGISTER_NET_LINKED(ENT_CLIENT_HOOK)
+REGISTER_NET_LINKED(ENT_CLIENT_TUBANOTE)
+
+REGISTER_NET_LINKED(ENT_CLIENT_SPAWNPOINT)
+REGISTER_NET_LINKED(ENT_CLIENT_SPAWNEVENT)
+REGISTER_NET_LINKED(ENT_CLIENT_WALL)
index dd5f3a164b58502f1b9bdacab31c4f1789145bbf..5cf3e1c6b1493972428805f13f07535ecb3a163d 100644 (file)
@@ -4,6 +4,7 @@
 #elif defined(MENUQC)
 #elif defined(SVQC)
        #include <common/constants.qh>
+       #include <common/net_linked.qh>
        #include <common/teams.qh>
        #include <server/autocvars.qh>
        #include <server/constants.qh>
index 0fde9e043904d00f4093fe74bcc45a9ce0a74b52..1f8cb00cb553a95623dec5d0eb10f3d0ca3c2e9f 100644 (file)
@@ -3,6 +3,7 @@
 #elif defined(MENUQC)
 #elif defined(SVQC)
     #include <common/constants.qh>
+    #include <common/net_linked.qh>
     #include <server/constants.qh>
     #include <server/defs.qh>
 #endif
index b6c3c9e01bea752c9d87f3d66685f3b9d596fedf..6408d6e3f2502aceebbe720c3151ccd8576dd9c2 100644 (file)
@@ -266,6 +266,8 @@ void make_safe_for_remove(entity this);
 #endif
 #undef ENGINE_EVENT
 
+#if XONOTIC
 #ifdef GAMEQC
        #include <ecs/_mod.qh>
 #endif
+#endif
index 4cc8458d51a4b0b359723f4f67b4db704bda544e..66613b53229ad6ef53d34a9ad43bc0b0ed413abd 100644 (file)
@@ -28,6 +28,7 @@
 #include <client/defs.qh>
 #include <client/main.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/physics/player.qh>
 #include <common/stats.qh>
 #include <common/triggers/trigger/viewloc.qh>
index 0f8ef06ac86a7fd890ca3a35bba045100b893050..dd8d5d33aaee2a8f479cd6edcc34f9047adf6730 100644 (file)
@@ -24,6 +24,7 @@
 #include "common.qh"
 #include <common/animdecide.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/util.qh>
 #include <server/constants.qh>
 #include <server/defs.qh>
index 698c9262370974781c1f0585caaba18103d19ff7..52583ff58a9bd14115848a356283b412b7c0c19f 100644 (file)
@@ -5,8 +5,6 @@
        #include "i18n.qh"
        #include "vector.qh"
 
-       #include <client/defs.qh>
-
        void Draw_CylindricLine(vector from, vector to, float thickness, string texture, float aspect, float shift, vector rgb, float theAlpha, float drawflag, vector vieworg)
        {
                // I want to draw a quad...
                drawstring_builtin(position, text, theScale, rgb, theAlpha, flag);
        }
 
+       float vid_conwidth; // TODO
        void drawstringcenter(vector position, string text, vector theScale, vector rgb, float theAlpha, int flag)
        {
                position.x = 0.5 * (vid_conwidth - 0.6025 * strlen(text) * theScale.x);
index 4854f092a0aba4d21b65675082913140dfb38d39..d68dc7d968ee14850297dc46b5ef744c76761a73 100644 (file)
@@ -1,3 +1,5 @@
 // generated file; do not modify
-#include <lib/matrix/command.qc>
+#if XONOTIC
+       #include <lib/matrix/command.qc>
+#endif
 #include <lib/matrix/matrix.qc>
index 965812297204137ccb73c865636c0784ca5002f3..c351afe8f7c91f41123a4d68effd731f7f79659a 100644 (file)
@@ -1,3 +1,5 @@
 // generated file; do not modify
-#include <lib/matrix/command.qh>
+#if XONOTIC
+       #include <lib/matrix/command.qh>
+#endif
 #include <lib/matrix/matrix.qh>
index 30ab014ec988f1a2fae062bbe36115b003257872..f0a9e817dcb4cc56defaebd1fbca4cfe34e97267 100644 (file)
@@ -313,12 +313,13 @@ USING(Stream, int);
                #define ReadInt48_t() vec3(ReadInt24_t(), ReadInt24_t(), 0)
                #define ReadInt72_t() vec3(ReadInt24_t(), ReadInt24_t(), ReadInt24_t())
 
-               int _ReadSByte;
+               noref int _ReadSByte;
                #define ReadSByte() (_ReadSByte = ReadByte(), (_ReadSByte & BIT(7) ? -128 : 0) + (_ReadSByte & BITS(7)))
                #define ReadFloat() ReadCoord()
                #define ReadVector() vec3(ReadFloat(), ReadFloat(), ReadFloat())
                #define ReadVector2D() vec3(ReadFloat(), ReadFloat(), 0)
 
+               float servertime; // TODO
                float ReadApproxPastTime()
                {
                        float dt = ReadByte();
index 34ea2610dedd7afa60e30ce6bab89f7df643940a..2e660827aa3149616933309094d927118b4a769a 100644 (file)
@@ -5,9 +5,9 @@
 #elif defined(MENUQC)
 #elif defined(SVQC)
        #include <common/constants.qh>
+       #include <common/net_linked.qh>
        #include <common/triggers/subs.qh>
        #include <common/util.qh>
-       #include <server/command/_mod.qh>
        #include <server/constants.qh>
        #include <server/defs.qh>
 #endif
index bdde55b9aa94683b7ffb0901229203fb1ff59116..2a7478dee2d7688322dfa3006b4534957159bcd3 100644 (file)
@@ -27,6 +27,7 @@
 
 #include <common/physics/player.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/teams.qh>
 #include <common/util.qh>
index 45051b6c270f1e738aa05786b3fbc9f54f1ecc34..56c36c0745a759e4236f3893ce08e327c12ee50f 100644 (file)
@@ -9,6 +9,7 @@
 #include "../waypoints.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/physics/player.qh>
 #include <common/state.qh>
 #include <common/items/_mod.qh>
index 17f61af141ff7c8b08a3d736011ae9a77043c705..7c71720c4c80ee49dfc2538093297ea65a8109d0 100644 (file)
@@ -10,6 +10,7 @@
 #include <common/items/_mod.qh>
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/triggers/trigger/jumppads.qh>
 
 .float speed;
index 5fb923799acfa41f863414a7ed96d33253874acd..c83d0f63c58dc2c4e3ebae76e9c50593ce85bd8c 100644 (file)
@@ -10,6 +10,7 @@
 #include "../../antilag.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 
 #include <lib/warpzone/common.qh>
 #include <lib/warpzone/util_server.qh>
index 9380fc4cde280f0cd9fda57a24cd6bddbd41da56..5017e81aba03014d4d325c3ddbb56fe0b9e36e2e 100644 (file)
@@ -5,6 +5,7 @@
 #include "../race.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/util.qh>
 
index a329ac9965efe463b052d92a24ac64b6ccddea1a..cbc65680a0aed6dcf309bd88ebd5069c61f87b5e 100644 (file)
@@ -21,6 +21,7 @@
 #include "../mutators/_mod.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/notifications/all.qh>
 #include <common/teams.qh>
index 361f1284436f9f85520c4902d80dfae92ea58203..d1cdb7e59db5a2c766aeb76ef907c7a5a198f64b 100644 (file)
@@ -13,6 +13,7 @@
 #include "../mutators/_mod.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/mapinfo.qh>
 #include <common/notifications/all.qh>
 #include <common/playerstats.qh>
index 1000a5105ba25da7332711ae91b3b6c3d0323f3e..1a8ada45fe306f9156bf74e789acf51de830f1bf 100644 (file)
@@ -2,9 +2,9 @@
 
 #if XONOTIC
 #include <server/_all.inc>
-#endif
 
 #include <ecs/_mod.inc>
+#endif
 
 #ifdef BUILD_MOD
 #include <mod/server/progs.inc>
index ed9006bb25eb493e2af8b5bfdb2dde217c5d0e70..7cc06da3e6dc05b32595b85556ff43d4ecb11225 100644 (file)
@@ -2,6 +2,7 @@
 
 #include "../mutators/_mod.qh"
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/teams.qh>
 #include <common/util.qh>
 #include <common/weapons/_all.qh>
index 03031c1580ac20a1ea3765190e4a58feda89c88a..6d163755067def2224a973db9bc311f1dcb60770 100644 (file)
@@ -2,6 +2,7 @@
 
 #include <common/t_items.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/deathtypes/all.qh>
 #include <common/notifications/all.qh>
 #include <common/util.qh>
index a8a893e217700750b4364106ba7fd6065ac3ae8f..9fcfd34c205b712ee1ff716693cd18415a860dbc 100644 (file)
@@ -5,6 +5,7 @@
 #include "../command/common.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/weapons/_all.qh>
 
 .float csqcprojectile_type;
index 56df6c3a2c47e615562c1bd190eba45241536c3f..539371a53cbe9c94b87e388deac95b290d1850cd 100644 (file)
@@ -3,6 +3,7 @@
 #include "weaponsystem.qh"
 #include <common/t_items.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/util.qh>
 #include <common/items/item.qh>
 #include <common/weapons/_all.qh>
index 3b7aa7bf893f7871bad4c5a2f54502c2a81aae8a..b49ed88f596ca00a7ef4e6b3467b7e5a3f36c2e2 100644 (file)
@@ -10,6 +10,7 @@
 #include "../antilag.qh"
 
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/util.qh>
 
 #include <common/weapons/_all.qh>
index 4968d3c31f4d2f813ac5cdddde94f167ec2b52e4..c0d302e2232123e9e3c049eed1965f27d750cf7b 100644 (file)
@@ -8,6 +8,7 @@
 #include <common/t_items.qh>
 #include <common/animdecide.qh>
 #include <common/constants.qh>
+#include <common/net_linked.qh>
 #include <common/monsters/_mod.qh>
 #include <common/notifications/all.qh>
 #include <common/util.qh>