From 0f64a49d36ce2363cb3052153b7d8e4f2addeb6c Mon Sep 17 00:00:00 2001 From: TimePath Date: Sat, 2 May 2015 14:40:48 +1000 Subject: [PATCH] Remove direct server #includes from client --- qcsrc/client/announcer.qc | 2 ++ qcsrc/client/bgmscript.qc | 2 ++ qcsrc/client/casings.qc | 1 + qcsrc/client/command/cl_cmd.qc | 5 +-- qcsrc/client/csqcmodel_hooks.qc | 8 +++-- qcsrc/client/damage.qc | 4 +++ qcsrc/client/effects.qc | 1 + qcsrc/client/gibs.qc | 1 + qcsrc/client/hook.qc | 3 ++ qcsrc/client/hud.qc | 5 ++- qcsrc/client/hud_config.qc | 2 ++ qcsrc/client/laser.qc | 3 ++ qcsrc/client/main.qc | 12 ++++++-- qcsrc/client/mapvoting.qc | 2 ++ qcsrc/client/miscfunctions.qc | 4 +++ qcsrc/client/movelib.qc | 1 + qcsrc/client/movelib.qh | 1 + qcsrc/client/movetypes.qc | 6 +++- qcsrc/client/particles.qc | 2 ++ qcsrc/client/player_skeleton.qc | 1 + qcsrc/client/prandom.qc | 1 + qcsrc/client/progs.src | 10 +++--- qcsrc/client/scoreboard.qc | 1 + qcsrc/client/shownames.qc | 3 ++ qcsrc/client/t_items.qc | 11 +++++++ qcsrc/client/t_items.qh | 1 + qcsrc/client/target_music.qc | 2 ++ qcsrc/client/teamradar.qc | 2 ++ qcsrc/client/tturrets.qc | 6 +++- qcsrc/client/tturrets.qh | 2 -- qcsrc/client/tuba.qc | 2 ++ qcsrc/client/vehicles/bumblebee.qc | 1 + qcsrc/client/vehicles/bumblebee.qh | 1 + qcsrc/client/vehicles/vehicles.qc | 5 ++- qcsrc/client/view.qc | 5 +++ qcsrc/client/wall.qc | 2 ++ qcsrc/client/waypointsprites.qc | 4 +++ qcsrc/client/weapons/projectile.qc | 3 ++ qcsrc/server/bot/havocbot/havocbot.qc | 1 + qcsrc/server/t_items.qc | 44 ++++++++++++--------------- qcsrc/server/vehicles/racer.qc | 5 ++- qcsrc/server/vehicles/racer.qh | 5 +++ qcsrc/server/vehicles/raptor.qc | 8 +---- qcsrc/server/vehicles/raptor.qh | 11 +++++++ qcsrc/server/vehicles/spiderbot.qc | 3 +- qcsrc/server/vehicles/spiderbot.qh | 5 +++ qcsrc/server/vehicles/vehicles.qh | 16 +++++----- qcsrc/test/compilationunit.sh | 8 ++++- qcsrc/warpzonelib/anglestransform.qc | 4 +-- qcsrc/warpzonelib/client.qc | 7 +++-- qcsrc/warpzonelib/common.qc | 8 ++--- qcsrc/warpzonelib/mathlib.qc | 5 ++- qcsrc/warpzonelib/server.qc | 11 ++++--- qcsrc/warpzonelib/util_server.qc | 10 +++--- 54 files changed, 196 insertions(+), 83 deletions(-) create mode 100644 qcsrc/client/movelib.qc create mode 100644 qcsrc/client/movelib.qh create mode 100644 qcsrc/client/t_items.qc create mode 100644 qcsrc/client/t_items.qh create mode 100644 qcsrc/client/vehicles/bumblebee.qc create mode 100644 qcsrc/client/vehicles/bumblebee.qh create mode 100644 qcsrc/server/vehicles/racer.qh create mode 100644 qcsrc/server/vehicles/raptor.qh create mode 100644 qcsrc/server/vehicles/spiderbot.qh diff --git a/qcsrc/client/announcer.qc b/qcsrc/client/announcer.qc index 5de03953c..30231d149 100644 --- a/qcsrc/client/announcer.qc +++ b/qcsrc/client/announcer.qc @@ -2,9 +2,11 @@ #include "autocvars.qh" #include "main.qh" + #include "../common/notifications.qh" #include "../common/stats.qh" #include "../common/util.qh" + #include "../dpdefs/csprogsdefs.qh" bool announcer_1min; diff --git a/qcsrc/client/bgmscript.qc b/qcsrc/client/bgmscript.qc index 70c4bab3f..d88622070 100644 --- a/qcsrc/client/bgmscript.qc +++ b/qcsrc/client/bgmscript.qc @@ -3,7 +3,9 @@ #include "autocvars.qh" #include "defs.qh" #include "main.qh" + #include "../common/util.qh" + #include "../dpdefs/csprogsdefs.qh" #define CONSTANT_SPEED_DECAY diff --git a/qcsrc/client/casings.qc b/qcsrc/client/casings.qc index c80c9bc6a..7dd79754c 100644 --- a/qcsrc/client/casings.qc +++ b/qcsrc/client/casings.qc @@ -6,6 +6,7 @@ #include "movetypes.qh" #include "prandom.qh" #include "rubble.qh" + #include "../common/util.qh" .float cnt; diff --git a/qcsrc/client/command/cl_cmd.qc b/qcsrc/client/command/cl_cmd.qc index 5a69fbbd0..d905ffc7f 100644 --- a/qcsrc/client/command/cl_cmd.qc +++ b/qcsrc/client/command/cl_cmd.qc @@ -12,10 +12,11 @@ #include "../main.qh" #include "../mapvoting.qh" #include "../miscfunctions.qh" -#include "../scoreboard.qh" + +#include "../../common/mapinfo.qh" + #include "../../common/command/generic.qh" #include "../../common/command/shared_defs.qh" -#include "../../common/mapinfo.qh" void DrawDebugModel() { diff --git a/qcsrc/client/csqcmodel_hooks.qc b/qcsrc/client/csqcmodel_hooks.qc index 2337266cf..5bef3cc9c 100644 --- a/qcsrc/client/csqcmodel_hooks.qc +++ b/qcsrc/client/csqcmodel_hooks.qc @@ -1,19 +1,23 @@ #include "csqcmodel_hooks.qh" +#include "autocvars.qh" #include "defs.qh" #include "gibs.qh" #include "main.qh" #include "miscfunctions.qh" #include "player_skeleton.qh" #include "sortlist.qh" -#include "../client/autocvars.qh" -#include "../client/weapons/projectile.qh" + +#include "weapons/projectile.qh" + #include "../common/animdecide.qh" #include "../common/csqcmodel_settings.qh" #include "../common/teams.qh" + #include "../csqcmodellib/cl_model.qh" #include "../csqcmodellib/cl_player.qh" #include "../csqcmodellib/interpolate.qh" + #include "../warpzonelib/mathlib.qh" .float death_time; diff --git a/qcsrc/client/damage.qc b/qcsrc/client/damage.qc index c962777c9..6826b03ce 100644 --- a/qcsrc/client/damage.qc +++ b/qcsrc/client/damage.qc @@ -5,11 +5,15 @@ #include "gibs.qh" #include "movetypes.qh" #include "prandom.qh" + #include "vehicles/vehicles.qh" + #include "../common/constants.qh" #include "../common/deathtypes.qh" #include "../common/util.qh" + #include "../common/weapons/weapons.qh" + #include "../dpdefs/csprogsdefs.qh" .entity tag_entity; diff --git a/qcsrc/client/effects.qc b/qcsrc/client/effects.qc index aa34ae22e..077c36a2a 100644 --- a/qcsrc/client/effects.qc +++ b/qcsrc/client/effects.qc @@ -1,6 +1,7 @@ #include "effects.qh" #include "autocvars.qh" + #include "../dpdefs/csprogsdefs.qh" /* diff --git a/qcsrc/client/gibs.qc b/qcsrc/client/gibs.qc index 8247f6a28..efdcd2e56 100644 --- a/qcsrc/client/gibs.qc +++ b/qcsrc/client/gibs.qc @@ -6,6 +6,7 @@ #include "movetypes.qh" #include "prandom.qh" #include "rubble.qh" + #include "../common/constants.qh" #include "../common/util.qh" diff --git a/qcsrc/client/hook.qc b/qcsrc/client/hook.qc index 0631de626..5d8394cd0 100644 --- a/qcsrc/client/hook.qc +++ b/qcsrc/client/hook.qc @@ -6,8 +6,11 @@ #include "main.qh" #include "miscfunctions.qh" #include "noise.qh" + #include "../common/teams.qh" + #include "../csqcmodellib/interpolate.qh" + #include "../warpzonelib/common.qh" #include "../warpzonelib/mathlib.qh" diff --git a/qcsrc/client/hud.qc b/qcsrc/client/hud.qc index 5a6a13737..0053541b1 100644 --- a/qcsrc/client/hud.qc +++ b/qcsrc/client/hud.qc @@ -8,6 +8,8 @@ #include "scoreboard.qh" #include "sortlist.qh" #include "teamradar.qh" +#include "t_items.qh" + #include "../common/buffs.qh" #include "../common/constants.qh" #include "../common/counting.qh" @@ -15,8 +17,9 @@ #include "../common/mapinfo.qh" #include "../common/nades.qh" #include "../common/stats.qh" + #include "../csqcmodellib/cl_player.qh" -#include "../server/t_items.qh" + #include "../warpzonelib/mathlib.qh" /* diff --git a/qcsrc/client/hud_config.qc b/qcsrc/client/hud_config.qc index 6a66edfb2..f6c3f53a7 100644 --- a/qcsrc/client/hud_config.qc +++ b/qcsrc/client/hud_config.qc @@ -4,7 +4,9 @@ #include "defs.qh" #include "hud.qh" #include "miscfunctions.qh" + #include "../common/constants.qh" + #include "../dpdefs/csprogsdefs.qh" #include "../dpdefs/keycodes.qh" diff --git a/qcsrc/client/laser.qc b/qcsrc/client/laser.qc index f3d60d54c..f0a9a4594 100644 --- a/qcsrc/client/laser.qc +++ b/qcsrc/client/laser.qc @@ -2,9 +2,12 @@ #include "hook.qh" #include "main.qh" + #include "../common/buffs.qh" + #include "../csqcmodellib/cl_model.qh" #include "../csqcmodellib/interpolate.qh" + #include "../dpdefs/csprogsdefs.qh" diff --git a/qcsrc/client/main.qc b/qcsrc/client/main.qc index f16e85ecc..5eafa68fa 100644 --- a/qcsrc/client/main.qc +++ b/qcsrc/client/main.qc @@ -21,10 +21,15 @@ #include "target_music.qh" #include "tturrets.qh" #include "tuba.qh" -#include "vehicles/vehicles.qh" +#include "t_items.qh" #include "wall.qh" #include "waypointsprites.qh" + +#include "vehicles/bumblebee.qh" +#include "vehicles/vehicles.qh" + #include "weapons/projectile.qh" + #include "../common/buffs.qh" #include "../common/deathtypes.qh" #include "../common/mapinfo.qh" @@ -34,11 +39,12 @@ #include "../common/notifications.qh" #include "../common/stats.qh" #include "../common/teams.qh" + #include "../common/weapons/weapons.qh" + #include "../csqcmodellib/cl_model.qh" #include "../csqcmodellib/interpolate.qh" -#include "../server/t_items.qh" -#include "../server/vehicles/bumblebee.qh" + #include "../warpzonelib/client.qh" // -------------------------------------------------------------------------- diff --git a/qcsrc/client/mapvoting.qc b/qcsrc/client/mapvoting.qc index 9b2191bc4..e0f8b0d23 100644 --- a/qcsrc/client/mapvoting.qc +++ b/qcsrc/client/mapvoting.qc @@ -6,8 +6,10 @@ #include "main.qh" #include "miscfunctions.qh" #include "scoreboard.qh" + #include "../common/mapinfo.qh" #include "../common/util.qh" + #include "../dpdefs/keycodes.qh" string MapVote_FormatMapItem(int id, string map, float _count, float maxwidth, vector fontsize) diff --git a/qcsrc/client/miscfunctions.qc b/qcsrc/client/miscfunctions.qc index d6aa38e04..ae88b424b 100644 --- a/qcsrc/client/miscfunctions.qc +++ b/qcsrc/client/miscfunctions.qc @@ -5,11 +5,15 @@ #include "hud.qh" #include "main.qh" #include "sortlist.qh" + #include "../common/command/generic.qh" + #include "../common/teams.qh" #include "../common/urllib.qh" #include "../common/util.qh" + #include "../csqcmodellib/cl_model.qh" + #include "../warpzonelib/mathlib.qh" void AuditLists() diff --git a/qcsrc/client/movelib.qc b/qcsrc/client/movelib.qc new file mode 100644 index 000000000..074f146dc --- /dev/null +++ b/qcsrc/client/movelib.qc @@ -0,0 +1 @@ +#include "../server/movelib.qc" diff --git a/qcsrc/client/movelib.qh b/qcsrc/client/movelib.qh new file mode 100644 index 000000000..a0634f6de --- /dev/null +++ b/qcsrc/client/movelib.qh @@ -0,0 +1 @@ +#include "../server/movelib.qh" diff --git a/qcsrc/client/movetypes.qc b/qcsrc/client/movetypes.qc index 6ffba0f13..88b549414 100644 --- a/qcsrc/client/movetypes.qc +++ b/qcsrc/client/movetypes.qc @@ -1,11 +1,15 @@ #include "movetypes.qh" #include "defs.qh" +#include "t_items.qh" + #include "../common/stats.qh" #include "../common/util.qh" + #include "../csqcmodellib/common.qh" + #include "../dpdefs/csprogsdefs.qh" -#include "../server/t_items.qh" + const int MOVEFLAG_GRAVITYUNAFFECTEDBYTICRATE = 4; diff --git a/qcsrc/client/particles.qc b/qcsrc/client/particles.qc index 334487c6b..24c01ce30 100644 --- a/qcsrc/client/particles.qc +++ b/qcsrc/client/particles.qc @@ -3,8 +3,10 @@ #include "autocvars.qh" #include "bgmscript.qh" #include "main.qh" + #include "../common/stats.qh" #include "../common/util.qh" + #include "../warpzonelib/common.qh" void Draw_PointParticles() diff --git a/qcsrc/client/player_skeleton.qc b/qcsrc/client/player_skeleton.qc index 74064c7ec..9df837229 100644 --- a/qcsrc/client/player_skeleton.qc +++ b/qcsrc/client/player_skeleton.qc @@ -1,6 +1,7 @@ #include "player_skeleton.qh" #include "../common/csqcmodel_settings.qh" + #include "../warpzonelib/anglestransform.qh" class(Skeleton) .float skeleton_info_modelindex; diff --git a/qcsrc/client/prandom.qc b/qcsrc/client/prandom.qc index 181300934..326248861 100644 --- a/qcsrc/client/prandom.qc +++ b/qcsrc/client/prandom.qc @@ -1,6 +1,7 @@ #include "prandom.qh" #include "../dpdefs/csprogsdefs.qh" + #include "../warpzonelib/mathlib.qh" // prandom - PREDICTABLE random number generator (not seeded yet) diff --git a/qcsrc/client/progs.src b/qcsrc/client/progs.src index 7ca2e54c4..c66554aa4 100644 --- a/qcsrc/client/progs.src +++ b/qcsrc/client/progs.src @@ -18,6 +18,7 @@ main.qc mapvoting.qc miscfunctions.qc modeleffects.qc +movelib.qc movetypes.qc noise.qc particles.qc @@ -31,13 +32,16 @@ target_music.qc teamradar.qc tturrets.qc tuba.qc -vehicles/vehicles.qc +t_items.qc view.qc wall.qc waypointsprites.qc command/cl_cmd.qc +vehicles/bumblebee.qc +vehicles/vehicles.qc + weapons/projectile.qc // TODO ../common/animdecide.qc @@ -63,10 +67,6 @@ weapons/projectile.qc // TODO ../csqcmodellib/cl_player.qc ../csqcmodellib/interpolate.qc -../server/movelib.qc -../server/t_items.qc -../server/vehicles/bumblebee.qc - ../warpzonelib/anglestransform.qc ../warpzonelib/client.qc ../warpzonelib/common.qc diff --git a/qcsrc/client/scoreboard.qc b/qcsrc/client/scoreboard.qc index e31656ac2..da947cc13 100644 --- a/qcsrc/client/scoreboard.qc +++ b/qcsrc/client/scoreboard.qc @@ -6,6 +6,7 @@ #include "main.qh" #include "miscfunctions.qh" #include "sortlist.qh" + #include "../common/constants.qh" #include "../common/counting.qh" #include "../common/mapinfo.qh" diff --git a/qcsrc/client/shownames.qc b/qcsrc/client/shownames.qc index 28b04b1d2..0ee3e512a 100644 --- a/qcsrc/client/shownames.qc +++ b/qcsrc/client/shownames.qc @@ -5,11 +5,14 @@ #include "hud.qh" #include "main.qh" #include "miscfunctions.qh" + #include "../common/constants.qh" #include "../common/mapinfo.qh" #include "../common/teams.qh" #include "../common/util.qh" + #include "../csqcmodellib/cl_model.qh" + #include "../dpdefs/csprogsdefs.qh" diff --git a/qcsrc/client/t_items.qc b/qcsrc/client/t_items.qc new file mode 100644 index 000000000..c319467db --- /dev/null +++ b/qcsrc/client/t_items.qc @@ -0,0 +1,11 @@ +#include "autocvars.qh" +#include "main.qh" +#include "movetypes.qh" +#include "../common/buffs.qh" +#include "../common/util.qh" +#include "../common/weapons/weapons.qh" +#include "../csqcmodellib/cl_model.qh" +#include "../csqcmodellib/common.qh" +#include "../dpdefs/csprogsdefs.qh" + +#include "../server/t_items.qc" diff --git a/qcsrc/client/t_items.qh b/qcsrc/client/t_items.qh new file mode 100644 index 000000000..eb016248f --- /dev/null +++ b/qcsrc/client/t_items.qh @@ -0,0 +1 @@ +#include "../server/t_items.qh" diff --git a/qcsrc/client/target_music.qc b/qcsrc/client/target_music.qc index 25ce2deb5..d72567cab 100644 --- a/qcsrc/client/target_music.qc +++ b/qcsrc/client/target_music.qc @@ -3,8 +3,10 @@ #include "autocvars.qh" #include "defs.qh" #include "main.qh" + #include "../common/constants.qh" #include "../common/util.qh" + #include "../warpzonelib/common.qh" .string noise; diff --git a/qcsrc/client/teamradar.qc b/qcsrc/client/teamradar.qc index 3ea3a757c..2d7c32702 100644 --- a/qcsrc/client/teamradar.qc +++ b/qcsrc/client/teamradar.qc @@ -5,7 +5,9 @@ #include "hud.qh" #include "main.qh" #include "miscfunctions.qh" + #include "../common/util.qh" + #include "../csqcmodellib/interpolate.qh" float vlen2d(vector v) diff --git a/qcsrc/client/tturrets.qc b/qcsrc/client/tturrets.qc index 22bacdcac..bcff5ede1 100644 --- a/qcsrc/client/tturrets.qc +++ b/qcsrc/client/tturrets.qc @@ -5,12 +5,16 @@ #include "hud.qh" #include "main.qh" #include "miscfunctions.qh" +#include "movelib.qh" #include "movetypes.qh" #include "prandom.qh" #include "teamradar.qh" #include "waypointsprites.qh" + #include "../common/teams.qh" -#include "../server/movelib.qh" + +#include "../server/tturrets/include/turrets_early.qh" + #include "../warpzonelib/anglestransform.qh" #include "../warpzonelib/mathlib.qh" diff --git a/qcsrc/client/tturrets.qh b/qcsrc/client/tturrets.qh index ab651e2fa..bf73dc82b 100644 --- a/qcsrc/client/tturrets.qh +++ b/qcsrc/client/tturrets.qh @@ -1,8 +1,6 @@ #ifndef TTURRETS_H #define TTURRETS_H -#include "../server/tturrets/include/turrets_early.qh" - void ent_turret(); void turrets_precache(); entityclass(Turret) diff --git a/qcsrc/client/tuba.qc b/qcsrc/client/tuba.qc index 93a7a8954..aa20b3508 100644 --- a/qcsrc/client/tuba.qc +++ b/qcsrc/client/tuba.qc @@ -2,8 +2,10 @@ #include "autocvars.qh" #include "main.qh" + #include "../common/constants.qh" #include "../common/util.qh" + #include "../warpzonelib/mathlib.qh" #define TUBA_STARTNOTE(i, n) strcat("weapons/tuba", (i ? ftos(i) : ""), "_loopnote", ftos(n), ".wav") diff --git a/qcsrc/client/vehicles/bumblebee.qc b/qcsrc/client/vehicles/bumblebee.qc new file mode 100644 index 000000000..7bfe31658 --- /dev/null +++ b/qcsrc/client/vehicles/bumblebee.qc @@ -0,0 +1 @@ +#include "../../server/vehicles/bumblebee.qc" diff --git a/qcsrc/client/vehicles/bumblebee.qh b/qcsrc/client/vehicles/bumblebee.qh new file mode 100644 index 000000000..411eb363c --- /dev/null +++ b/qcsrc/client/vehicles/bumblebee.qh @@ -0,0 +1 @@ +#include "../../server/vehicles/bumblebee.qh" diff --git a/qcsrc/client/vehicles/vehicles.qc b/qcsrc/client/vehicles/vehicles.qc index 1cc907296..db1df041d 100644 --- a/qcsrc/client/vehicles/vehicles.qc +++ b/qcsrc/client/vehicles/vehicles.qc @@ -8,13 +8,16 @@ #include "../movetypes.qh" #include "../prandom.qh" #include "../scoreboard.qh" +#include "../t_items.qh" + #include "../../common/buffs.qh" #include "../../common/constants.qh" #include "../../common/stats.qh" #include "../../common/util.qh" + #include "../../csqcmodellib/cl_model.qh" + #include "../../dpdefs/csprogsdefs.qh" -#include "../../server/t_items.qh" .float cnt; diff --git a/qcsrc/client/view.qc b/qcsrc/client/view.qc index 8167cb1bd..1a75fa0ef 100644 --- a/qcsrc/client/view.qc +++ b/qcsrc/client/view.qc @@ -13,15 +13,20 @@ #include "target_music.qh" #include "vehicles/vehicles.qh" #include "waypointsprites.qh" + #include "../common/constants.qh" #include "../common/mapinfo.qh" #include "../common/nades.qh" #include "../common/stats.qh" #include "../common/teams.qh" #include "../common/util.qh" + #include "../common/weapons/weapons.qh" + #include "../csqcmodellib/cl_player.qh" + #include "../dpdefs/csprogsdefs.qh" + #include "../warpzonelib/client.qh" #include "../warpzonelib/common.qh" #include "../warpzonelib/mathlib.qh" diff --git a/qcsrc/client/wall.qc b/qcsrc/client/wall.qc index 11b851f8a..98a2318d7 100644 --- a/qcsrc/client/wall.qc +++ b/qcsrc/client/wall.qc @@ -3,7 +3,9 @@ #include "autocvars.qh" #include "bgmscript.qh" #include "main.qh" + #include "../common/util.qh" + #include "../csqcmodellib/interpolate.qh" .float alpha; diff --git a/qcsrc/client/waypointsprites.qc b/qcsrc/client/waypointsprites.qc index c26f42af4..34c1d0898 100644 --- a/qcsrc/client/waypointsprites.qc +++ b/qcsrc/client/waypointsprites.qc @@ -6,11 +6,15 @@ #include "main.qh" #include "miscfunctions.qh" #include "teamradar.qh" + #include "../common/buffs.qh" #include "../common/constants.qh" #include "../common/teams.qh" + #include "../common/weapons/weapons.qh" + #include "../csqcmodellib/interpolate.qh" + #include "../warpzonelib/mathlib.qh" .float alpha; diff --git a/qcsrc/client/weapons/projectile.qc b/qcsrc/client/weapons/projectile.qc index 0da47f97b..cd4f9b744 100644 --- a/qcsrc/client/weapons/projectile.qc +++ b/qcsrc/client/weapons/projectile.qc @@ -4,10 +4,13 @@ #include "../defs.qh" #include "../main.qh" #include "../movetypes.qh" + #include "../../common/constants.qh" #include "../../common/nades.qh" #include "../../common/util.qh" + #include "../../csqcmodellib/interpolate.qh" + #include "../../warpzonelib/anglestransform.qh" .float alpha; diff --git a/qcsrc/server/bot/havocbot/havocbot.qc b/qcsrc/server/bot/havocbot/havocbot.qc index 347a85204..f05df2886 100644 --- a/qcsrc/server/bot/havocbot/havocbot.qc +++ b/qcsrc/server/bot/havocbot/havocbot.qc @@ -1,4 +1,5 @@ #include "havocbot.qh" + #include "role_onslaught.qc" #include "role_keyhunt.qc" #include "roles.qc" diff --git a/qcsrc/server/t_items.qc b/qcsrc/server/t_items.qc index 1a4a7586c..8a5ac17b1 100644 --- a/qcsrc/server/t_items.qc +++ b/qcsrc/server/t_items.qc @@ -1,31 +1,27 @@ -#if defined(CSQC) - #include "../dpdefs/csprogsdefs.qh" - #include "../common/util.qh" - #include "../common/buffs.qh" - #include "../common/weapons/weapons.qh" - #include "../client/autocvars.qh" - #include "../client/movetypes.qh" - #include "../client/main.qh" - #include "../csqcmodellib/common.qh" - #include "../csqcmodellib/cl_model.qh" - #include "t_items.qh" -#elif defined(MENUQC) -#elif defined(SVQC) - #include "../dpdefs/progsdefs.qh" - #include "../dpdefs/dpextensions.qh" - #include "../warpzonelib/util_server.qh" - #include "../common/constants.qh" - #include "../common/util.qh" - #include "../common/monsters/monsters.qh" - #include "../common/weapons/weapons.qh" - #include "weapons/weaponsystem.qh" - #include "t_items.qh" +#include "t_items.qh" + +#if defined(SVQC) #include "autocvars.qh" #include "constants.qh" #include "defs.qh" - #include "../common/notifications.qh" - #include "../common/deathtypes.qh" + #include "mutators/mutators_include.qh" + + #include "weapons/weaponsystem.qh" + + #include "../common/constants.qh" + #include "../common/deathtypes.qh" + #include "../common/notifications.qh" + #include "../common/util.qh" + + #include "../common/monsters/monsters.qh" + + #include "../common/weapons/weapons.qh" + + #include "../dpdefs/dpextensions.qh" + #include "../dpdefs/progsdefs.qh" + + #include "../warpzonelib/util_server.qh" #endif #ifdef CSQC diff --git a/qcsrc/server/vehicles/racer.qc b/qcsrc/server/vehicles/racer.qc index dce126c0e..b96419584 100644 --- a/qcsrc/server/vehicles/racer.qc +++ b/qcsrc/server/vehicles/racer.qc @@ -1,5 +1,4 @@ -const vector RACER_MIN = '-120 -120 -40'; -const vector RACER_MAX = '120 120 40'; +#include "racer.qh" #ifdef SVQC void racer_exit(float eject); @@ -680,4 +679,4 @@ void spawnfunc_vehicle_racer() return; } } -#endif // SVQC \ No newline at end of file +#endif // SVQC diff --git a/qcsrc/server/vehicles/racer.qh b/qcsrc/server/vehicles/racer.qh new file mode 100644 index 000000000..0051b7789 --- /dev/null +++ b/qcsrc/server/vehicles/racer.qh @@ -0,0 +1,5 @@ +#ifndef RACER_H +#define RACER_H +const vector RACER_MIN = '-120 -120 -40'; +const vector RACER_MAX = '120 120 40'; +#endif diff --git a/qcsrc/server/vehicles/raptor.qc b/qcsrc/server/vehicles/raptor.qc index 4bd283693..74d3c7a68 100644 --- a/qcsrc/server/vehicles/raptor.qc +++ b/qcsrc/server/vehicles/raptor.qc @@ -1,10 +1,4 @@ -const float RSM_FIRST = 0; -const float RSM_BOMB = 0; -const float RSM_FLARE = 1; -const float RSM_LAST = 1; - -const vector RAPTOR_MIN = '-80 -80 0'; -const vector RAPTOR_MAX = '80 80 70'; +#include "raptor.qh" #ifdef SVQC float autocvar_g_vehicle_raptor; diff --git a/qcsrc/server/vehicles/raptor.qh b/qcsrc/server/vehicles/raptor.qh new file mode 100644 index 000000000..0043789dc --- /dev/null +++ b/qcsrc/server/vehicles/raptor.qh @@ -0,0 +1,11 @@ +#ifndef RAPTOR_H +#define RAPTOR_H +const float RSM_FIRST = 0; +const float RSM_BOMB = 0; +const float RSM_FLARE = 1; +const float RSM_LAST = 1; + +const vector RAPTOR_MIN = '-80 -80 0'; +const vector RAPTOR_MAX = '80 80 70'; + +#endif diff --git a/qcsrc/server/vehicles/spiderbot.qc b/qcsrc/server/vehicles/spiderbot.qc index c969e225e..10ab353ec 100644 --- a/qcsrc/server/vehicles/spiderbot.qc +++ b/qcsrc/server/vehicles/spiderbot.qc @@ -1,5 +1,4 @@ -const vector SPIDERBOT_MIN = '-75 -75 10'; -const vector SPIDERBOT_MAX = '75 75 125'; +#include "spiderbot.qh" #ifdef SVQC float autocvar_g_vehicle_spiderbot; diff --git a/qcsrc/server/vehicles/spiderbot.qh b/qcsrc/server/vehicles/spiderbot.qh new file mode 100644 index 000000000..ce968585c --- /dev/null +++ b/qcsrc/server/vehicles/spiderbot.qh @@ -0,0 +1,5 @@ +#ifndef SPIDERBOT_H +#define SPIDERBOT_H +const vector SPIDERBOT_MIN = '-75 -75 10'; +const vector SPIDERBOT_MAX = '75 75 125'; +#endif diff --git a/qcsrc/server/vehicles/vehicles.qh b/qcsrc/server/vehicles/vehicles.qh index e6b976096..ec152d7f7 100644 --- a/qcsrc/server/vehicles/vehicles.qh +++ b/qcsrc/server/vehicles/vehicles.qh @@ -2,13 +2,15 @@ #define VEHICLES_H #ifdef VEHICLES_ENABLED -#include "vehicles.qc" +# include "vehicles.qc" -#include "racer.qc" -#include "spiderbot.qc" -#include "raptor.qc" -#ifndef VEHICLES_NO_UNSTABLE -#include "bumblebee.qc" -#endif +# include "racer.qc" +# include "raptor.qc" +# include "spiderbot.qc" + +# ifndef VEHICLES_NO_UNSTABLE +# include "bumblebee.qc" +# endif #endif + #endif diff --git a/qcsrc/test/compilationunit.sh b/qcsrc/test/compilationunit.sh index fb893848f..7af726f4c 100755 --- a/qcsrc/test/compilationunit.sh +++ b/qcsrc/test/compilationunit.sh @@ -15,4 +15,10 @@ function check() { } clientdefs=("-DCSQC" "common/util-pre.qh" "dpdefs/csprogsdefs.qh") -check client clientdefs[@] +check "client" clientdefs[@] + +# serverdefs=("-DSVQC" "common/util-pre.qh" "server/sys-pre.qh" "dpdefs/progsdefs.qh" "dpdefs/dpextensions.qh" "server/sys-post.qh" "server/defs.qh" "server/autocvars.qh") +# check "server" serverdefs[@] + +# menudefs=("-DMENUQC" "common/util-pre.qh" "dpdefs/menudefs.qh" "menu/oo/interface.qc" "menu/oo/implementation.qc") +# check "menu" menudefs[@] diff --git a/qcsrc/warpzonelib/anglestransform.qc b/qcsrc/warpzonelib/anglestransform.qc index e8a455b6e..079ceaa7d 100644 --- a/qcsrc/warpzonelib/anglestransform.qc +++ b/qcsrc/warpzonelib/anglestransform.qc @@ -1,11 +1,11 @@ +#include "anglestransform.qh" + #if defined(CSQC) #include "../dpdefs/csprogsdefs.qh" - #include "anglestransform.qh" #elif defined(MENUQC) #elif defined(SVQC) #include "../dpdefs/progsdefs.qh" #include "../dpdefs/dpextensions.qh" - #include "anglestransform.qh" #endif #ifdef POSITIVE_PITCH_IS_DOWN diff --git a/qcsrc/warpzonelib/client.qc b/qcsrc/warpzonelib/client.qc index 5c2609a7d..e0bb64345 100644 --- a/qcsrc/warpzonelib/client.qc +++ b/qcsrc/warpzonelib/client.qc @@ -1,9 +1,10 @@ +#include "client.qh" +#include "common.qh" + #if defined(CSQC) - #include "../dpdefs/csprogsdefs.qh" - #include "common.qh" - #include "client.qh" #include "../client/autocvars.qh" #include "../csqcmodellib/cl_model.qh" + #include "../dpdefs/csprogsdefs.qh" #elif defined(MENUQC) #elif defined(SVQC) #endif diff --git a/qcsrc/warpzonelib/common.qc b/qcsrc/warpzonelib/common.qc index aa0de9119..0734811c1 100644 --- a/qcsrc/warpzonelib/common.qc +++ b/qcsrc/warpzonelib/common.qc @@ -1,13 +1,13 @@ +#include "common.qh" + #if defined(CSQC) #include "../dpdefs/csprogsdefs.qh" - #include "common.qh" #include "../server/t_items.qh" #elif defined(MENUQC) #elif defined(SVQC) - #include "../dpdefs/progsdefs.qh" - #include "../dpdefs/dpextensions.qh" - #include "common.qh" #include "../common/weapons/weapons.qh" + #include "../dpdefs/dpextensions.qh" + #include "../dpdefs/progsdefs.qh" #endif void WarpZone_Accumulator_Clear(entity acc) diff --git a/qcsrc/warpzonelib/mathlib.qc b/qcsrc/warpzonelib/mathlib.qc index c9cde9072..395547036 100644 --- a/qcsrc/warpzonelib/mathlib.qc +++ b/qcsrc/warpzonelib/mathlib.qc @@ -1,11 +1,10 @@ +#include "mathlib.qh" #if defined(CSQC) #include "../dpdefs/csprogsdefs.qh" - #include "mathlib.qh" #elif defined(MENUQC) #elif defined(SVQC) - #include "../dpdefs/progsdefs.qh" #include "../dpdefs/dpextensions.qh" - #include "mathlib.qh" + #include "../dpdefs/progsdefs.qh" #endif int fpclassify(float x) diff --git a/qcsrc/warpzonelib/server.qc b/qcsrc/warpzonelib/server.qc index a9380070b..bd6266ea0 100644 --- a/qcsrc/warpzonelib/server.qc +++ b/qcsrc/warpzonelib/server.qc @@ -1,15 +1,16 @@ +#include "server.qh" + +#include "common.qh" #if defined(CSQC) #elif defined(MENUQC) #elif defined(SVQC) - #include "../dpdefs/progsdefs.qh" - #include "../dpdefs/dpextensions.qh" - #include "common.qh" - #include "server.qh" #include "../common/constants.qh" #include "../common/util.qh" + #include "../dpdefs/dpextensions.qh" + #include "../dpdefs/progsdefs.qh" + #include "../server/command/common.qh" #include "../server/constants.qh" #include "../server/defs.qh" - #include "../server/command/common.qh" #endif #ifdef WARPZONELIB_KEEPDEBUG diff --git a/qcsrc/warpzonelib/util_server.qc b/qcsrc/warpzonelib/util_server.qc index b94eafbda..e82c4ba6e 100644 --- a/qcsrc/warpzonelib/util_server.qc +++ b/qcsrc/warpzonelib/util_server.qc @@ -1,11 +1,13 @@ +#include "util_server.qh" + +#include "common.qh" + #if defined(CSQC) #elif defined(MENUQC) #elif defined(SVQC) - #include "../dpdefs/progsdefs.qh" - #include "../dpdefs/dpextensions.qh" - #include "common.qh" - #include "util_server.qh" #include "../csqcmodellib/sv_model.qh" + #include "../dpdefs/dpextensions.qh" + #include "../dpdefs/progsdefs.qh" #endif void WarpZoneLib_MoveOutOfSolid_Expand(entity e, vector by) -- 2.39.2