]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make most server includes order insensitive
authorTimePath <andrew.hardaker1995@gmail.com>
Sat, 2 May 2015 12:28:02 +0000 (22:28 +1000)
committerTimePath <andrew.hardaker1995@gmail.com>
Sat, 2 May 2015 12:28:02 +0000 (22:28 +1000)
153 files changed:
qcsrc/client/_.qh
qcsrc/client/csqc_constants.qc [deleted file]
qcsrc/client/csqc_constants.qh [new file with mode: 0644]
qcsrc/common/buffs.qh
qcsrc/common/notifications.qh
qcsrc/dpdefs/csprogsdefs.qh
qcsrc/dpdefs/dpextensions.qh
qcsrc/server/_.qh [new file with mode: 0644]
qcsrc/server/bot/aim.qc
qcsrc/server/bot/aim.qh
qcsrc/server/bot/bot.qc
qcsrc/server/bot/bot.qh
qcsrc/server/bot/havocbot/havocbot.qc
qcsrc/server/bot/havocbot/role_keyhunt.qc
qcsrc/server/bot/havocbot/role_keyhunt.qh [new file with mode: 0644]
qcsrc/server/bot/havocbot/role_onslaught.qc
qcsrc/server/bot/havocbot/role_onslaught.qh [new file with mode: 0644]
qcsrc/server/bot/havocbot/roles.qc
qcsrc/server/bot/havocbot/roles.qh [new file with mode: 0644]
qcsrc/server/bot/havocbot/scripting.qh [new file with mode: 0644]
qcsrc/server/bot/navigation.qc
qcsrc/server/bot/navigation.qh
qcsrc/server/bot/scripting.qc
qcsrc/server/bot/scripting.qh [new file with mode: 0644]
qcsrc/server/bot/waypoints.qc
qcsrc/server/cheats.qc
qcsrc/server/cheats.qh
qcsrc/server/cl_client.qc
qcsrc/server/cl_client.qh [new file with mode: 0644]
qcsrc/server/cl_impulse.qc
qcsrc/server/cl_physics.qc
qcsrc/server/cl_player.qc
qcsrc/server/command/banning.qc
qcsrc/server/command/banning.qh
qcsrc/server/command/cmd.qc
qcsrc/server/command/common.qc
qcsrc/server/command/getreplies.qc
qcsrc/server/command/radarmap.qc
qcsrc/server/command/radarmap.qh
qcsrc/server/command/sv_cmd.qc
qcsrc/server/command/vote.qc
qcsrc/server/command/vote.qh
qcsrc/server/csqceffects.qh [new file with mode: 0644]
qcsrc/server/ent_cs.qc
qcsrc/server/func_breakable.qc
qcsrc/server/g_casings.qc
qcsrc/server/g_damage.qc
qcsrc/server/g_hook.qc
qcsrc/server/g_lights.qc
qcsrc/server/g_models.qc
qcsrc/server/g_subs.qc
qcsrc/server/g_triggers.qc
qcsrc/server/g_violence.qc
qcsrc/server/g_world.qc
qcsrc/server/g_world.qh
qcsrc/server/ipban.qc
qcsrc/server/item_key.qc
qcsrc/server/mapvoting.qc
qcsrc/server/mapvoting.qh
qcsrc/server/miscfunctions.qc
qcsrc/server/miscfunctions.qh
qcsrc/server/mutators/base.qc
qcsrc/server/mutators/gamemode.qh [new file with mode: 0644]
qcsrc/server/mutators/gamemode_assault.qc
qcsrc/server/mutators/gamemode_ca.qc
qcsrc/server/mutators/gamemode_ctf.qc
qcsrc/server/mutators/gamemode_ctf.qh
qcsrc/server/mutators/gamemode_cts.qc
qcsrc/server/mutators/gamemode_domination.qc
qcsrc/server/mutators/gamemode_freezetag.qc
qcsrc/server/mutators/gamemode_freezetag.qh [new file with mode: 0644]
qcsrc/server/mutators/gamemode_invasion.qc
qcsrc/server/mutators/gamemode_keepaway.qc
qcsrc/server/mutators/gamemode_keepaway.qh
qcsrc/server/mutators/gamemode_keyhunt.qc
qcsrc/server/mutators/gamemode_keyhunt.qh
qcsrc/server/mutators/gamemode_lms.qc
qcsrc/server/mutators/gamemode_nexball.qc
qcsrc/server/mutators/gamemode_onslaught.qc
qcsrc/server/mutators/gamemode_race.qc
qcsrc/server/mutators/gamemode_tdm.qc
qcsrc/server/mutators/mutator.qh [new file with mode: 0644]
qcsrc/server/mutators/mutator_bloodloss.qc
qcsrc/server/mutators/mutator_buffs.qc
qcsrc/server/mutators/mutator_campcheck.qc
qcsrc/server/mutators/mutator_dodging.qc
qcsrc/server/mutators/mutator_instagib.qc
qcsrc/server/mutators/mutator_invincibleproj.qc
qcsrc/server/mutators/mutator_melee_only.qc
qcsrc/server/mutators/mutator_midair.qc
qcsrc/server/mutators/mutator_multijump.qc
qcsrc/server/mutators/mutator_nades.qc
qcsrc/server/mutators/mutator_new_toys.qc
qcsrc/server/mutators/mutator_nix.qc
qcsrc/server/mutators/mutator_overkill.qc
qcsrc/server/mutators/mutator_physical_items.qc
qcsrc/server/mutators/mutator_pinata.qc
qcsrc/server/mutators/mutator_random_gravity.qc
qcsrc/server/mutators/mutator_rocketflying.qc
qcsrc/server/mutators/mutator_spawn_near_teammate.qc
qcsrc/server/mutators/mutator_superspec.qc
qcsrc/server/mutators/mutator_touchexplode.qc
qcsrc/server/mutators/mutator_vampire.qc
qcsrc/server/mutators/sandbox.qc
qcsrc/server/pathlib.qc
qcsrc/server/pathlib.qh [new file with mode: 0644]
qcsrc/server/pathlib/costs.qc
qcsrc/server/pathlib/debug.qc
qcsrc/server/pathlib/expandnode.qc
qcsrc/server/pathlib/main.qc
qcsrc/server/pathlib/main.qh [new file with mode: 0644]
qcsrc/server/pathlib/movenode.qc
qcsrc/server/pathlib/path_waypoint.qc
qcsrc/server/pathlib/pathlib.qh
qcsrc/server/pathlib/utility.qc
qcsrc/server/pathlib/utility.qh [new file with mode: 0644]
qcsrc/server/portals.qc
qcsrc/server/progs.src
qcsrc/server/race.qc
qcsrc/server/race.qh
qcsrc/server/round_handler.qc
qcsrc/server/scores.qc
qcsrc/server/scores.qh
qcsrc/server/scores_rules.qc
qcsrc/server/scores_rules.qh [new file with mode: 0644]
qcsrc/server/secret.qc
qcsrc/server/spawnpoints.qc
qcsrc/server/steerlib.qc
qcsrc/server/steerlib.qh [new file with mode: 0644]
qcsrc/server/sv_main.qc
qcsrc/server/t_halflife.qc
qcsrc/server/t_items.qc
qcsrc/server/t_items.qh
qcsrc/server/t_jumppads.qc
qcsrc/server/t_plats.qc
qcsrc/server/t_quake.qc
qcsrc/server/t_quake3.qc
qcsrc/server/t_swamp.qc
qcsrc/server/t_teleporters.qc
qcsrc/server/target_music.qc
qcsrc/server/target_spawn.qc
qcsrc/server/teamplay.qc
qcsrc/server/tturrets/system/system_main.qc
qcsrc/server/tturrets/units/unit_ewheel.qc
qcsrc/server/tturrets/units/unit_machinegun.qc
qcsrc/server/tturrets/units/unit_phaser.qc
qcsrc/server/tturrets/units/unit_targettrigger.qc
qcsrc/server/tturrets/units/unit_tessla.qc
qcsrc/server/tturrets/units/unit_walker.qc
qcsrc/server/vehicles/bumblebee.qc
qcsrc/server/vehicles/racer.qc
qcsrc/server/vehicles/vehicles.qc
qcsrc/test/compilationunit.sh

index 8b811bceba0fa2aa64d289b0d4ab8e23f399ee4c..c8ff79d58b6f142fdd47f4492258f40e2057508a 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef __H
-#define __H
+#ifndef CLIENT___H
+#define CLIENT___H
 
 #include "autocvars.qh"
 #include "defs.qh"
 
 #include "autocvars.qh"
 #include "defs.qh"
diff --git a/qcsrc/client/csqc_constants.qc b/qcsrc/client/csqc_constants.qc
deleted file mode 100644 (file)
index f11c31c..0000000
+++ /dev/null
@@ -1,143 +0,0 @@
-// MenuQC redefines world, change define it here to be safe
-#define world world
-
-// Mask Constants (set .drawmask on entities; use R_AddEntities to add all entities based on mask)
-const int              MASK_ENGINE                                             = 1;
-const int              MASK_ENGINEVIEWMODELS                   = 2;
-const int              MASK_NORMAL                                             = 4;
-
-// Renderflag Constants (used for CSQC entities)
-const int              RF_VIEWMODEL                                    = 1;
-const int              RF_EXTERNALMODEL                                = 2;
-const int              RF_DEPTHHACK                                    = 4;
-const int              RF_ADDITIVE                                             = 8;
-const int              RF_USEAXIS                                              = 16;
-
-// Viewflag Constants (use with R_SetView)
-const int              VF_MIN                                                  = 1;    //(vector)
-const int              VF_MIN_X                                                = 2;    //(float)
-const int              VF_MIN_Y                                                = 3;    //(float)
-const int              VF_SIZE                                                 = 4;    //(vector) (viewport size)
-const int              VF_SIZE_Y                                               = 5;    //(float)
-const int              VF_SIZE_X                                               = 6;    //(float)
-const int              VF_VIEWPORT                                             = 7;    //(vector, vector)
-const int              VF_FOV                                                  = 8;    //(vector)
-const int              VF_FOVX                                                 = 9;    //(float)
-const int              VF_FOVY                                                 = 10;   //(float)
-const int              VF_ORIGIN                                               = 11;   //(vector)
-const int              VF_ORIGIN_X                                             = 12;   //(float)
-const int              VF_ORIGIN_Y                                             = 13;   //(float)
-const int              VF_ORIGIN_Z                                             = 14;   //(float)
-const int              VF_ANGLES                                               = 15;   //(vector)
-const int              VF_ANGLES_X                                             = 16;   //(float)
-const int              VF_ANGLES_Y                                             = 17;   //(float)
-const int              VF_ANGLES_Z                                             = 18;   //(float)
-const int              VF_DRAWWORLD                                    = 19;   //(float)
-const int              VF_DRAWENGINEHUD                                = 20;   //(float)
-const int              VF_DRAWCROSSHAIR                                = 21;   //(float)
-const int              VF_PERSPECTIVE                                  = 200;  //(float)
-
-const int              VF_CL_VIEWANGLES                                = 33;   //(vector)
-const int              VF_CL_VIEWANGLES_X                              = 34;   //(float)
-const int              VF_CL_VIEWANGLES_Y                              = 35;   //(float)
-const int              VF_CL_VIEWANGLES_Z                              = 36;   //(float)
-
-// Quake-style Point Contents
-const int              CONTENT_EMPTY                                   = -1;
-const int              CONTENT_SOLID                                   = -2;
-const int              CONTENT_WATER                                   = -3;
-const int              CONTENT_SLIME                                   = -4;
-const int              CONTENT_LAVA                                    = -5;
-const int              CONTENT_SKY                                             = -6;
-
-// Vector / Hull Constants
-const vector   VEC_1                                                   = '1 1 1';
-const vector   VEC_0                                                   = '0 0 0';
-const vector   VEC_M1                                                  = '-1 -1 -1';
-
-const vector   VEC_HULL_MIN                                    = '-16 -16 -24';
-const vector   VEC_HULL_MAX                                    = '16 16 32';
-
-// Effect Constants
-const int      EF_NODRAW                                               = 16;
-const int      EF_ADDITIVE                                             = 32;
-const int      EF_BLUE                                                 = 64;
-const int      EF_RED                                                  = 128;
-const int      EF_FULLBRIGHT                                   = 512;
-const int      EF_FLAME                                                = 1024;
-const int      EF_STARDUST                                             = 2048;
-const int      EF_NOSHADOW                                             = 4096;
-const int      EF_NODEPTHTEST                                  = 8192;
-
-// Quake Player Flag Constants
-const int      PFL_ONGROUND                                    = 1;
-const int      PFL_CROUCH                                              = 2;
-const int      PFL_DEAD                                                = 4;
-const int      PFL_GIBBED                                              = 8;
-
-// Quake Temporary Entity Constants
-const int              TE_SPIKE                                                = 0;
-const int              TE_SUPERSPIKE                                   = 1;
-const int              TE_GUNSHOT                                              = 2;
-const int              TE_EXPLOSION                                    = 3;
-const int              TE_TAREXPLOSION                                 = 4;
-const int              TE_LIGHTNING1                                   = 5;
-const int              TE_LIGHTNING2                                   = 6;
-const int              TE_WIZSPIKE                                             = 7;
-const int              TE_KNIGHTSPIKE                                  = 8;
-const int              TE_LIGHTNING3                                   = 9;
-const int              TE_LAVASPLASH                                   = 10;
-const int              TE_TELEPORT                                             = 11;
-const int      TE_EXPLOSION2                                   = 12;
-// Darkplaces Additions
-const int      TE_EXPLOSIONRGB                                 = 53;
-const int              TE_GUNSHOTQUAD                                  = 57;
-const int              TE_EXPLOSIONQUAD                                = 70;
-
-// Math Constants
-const int      EXTRA_LOW                                               = -99999999;
-const int      EXTRA_HIGH                                              = 99999999;
-
-// Frik File Constants
-const int              FILE_READ                                               = 0;
-const int              FILE_APPEND                                             = 1;
-const int              FILE_WRITE                                              = 2;
-
-// Button values used by input_buttons
-const int BUTTON_ATTACK = 1;
-const int BUTTON_JUMP = 2;
-const int BUTTON_3 = 4;
-const int BUTTON_4 = 8;
-const int BUTTON_5 = 16;
-const int BUTTON_6 = 32;
-const int BUTTON7 = 64;
-const int BUTTON8 = 128;
-const int BUTTON_USE = 256;
-const int BUTTON_CHAT = 512;
-const int BUTTON_PRYDONCURSOR = 1024;
-const int BUTTON_9 = 2048;
-const int BUTTON_10 = 4096;
-const int BUTTON_11 = 8192;
-const int BUTTON_12 = 16384;
-const int BUTTON_13 = 32768;
-const int BUTTON_14 = 65536;
-const int BUTTON_15 = 131072;
-const int BUTTON_16 = 262144;
-
-const int SOLID_NOT            = 0; // no interaction with other objects
-const int SOLID_TRIGGER        = 1; // touch on edge, but not blocking
-const int SOLID_BBOX           = 2; // touch on edge, block
-const int SOLID_SLIDEBOX       = 3; // touch on edge, but not an onground
-const int SOLID_BSP            = 4; // bsp clip, touch on edge, block
-const int SOLID_CORPSE         = 5; // same as SOLID_BBOX, except it behaves as SOLID_NOT against SOLID_SLIDEBOX objects (players/monsters)
-
-const int MOVE_NORMAL = 0; // same as false
-const int MOVE_NOMONSTERS = 1; // same as true
-const int MOVE_MISSILE = 2; // save as movement with .movetype == MOVETYPE_FLYMISSILE
-const int MOVE_HITMODEL = 4;
-const int MOVE_WORLDONLY = 3;
-
-const int CAMERA_FREE = 1;
-const int CAMERA_CHASE = 2;
-
-const int EF_NOMODELFLAGS = 8388608;
diff --git a/qcsrc/client/csqc_constants.qh b/qcsrc/client/csqc_constants.qh
new file mode 100644 (file)
index 0000000..09d217b
--- /dev/null
@@ -0,0 +1,148 @@
+#ifndef CSQC_CONSTANTS
+#define CSQC_CONSTANTS
+
+// MenuQC redefines world, change define it here to be safe
+#define world world
+
+// Mask Constants (set .drawmask on entities; use R_AddEntities to add all entities based on mask)
+const int              MASK_ENGINE                                             = 1;
+const int              MASK_ENGINEVIEWMODELS                   = 2;
+const int              MASK_NORMAL                                             = 4;
+
+// Renderflag Constants (used for CSQC entities)
+const int              RF_VIEWMODEL                                    = 1;
+const int              RF_EXTERNALMODEL                                = 2;
+const int              RF_DEPTHHACK                                    = 4;
+const int              RF_ADDITIVE                                             = 8;
+const int              RF_USEAXIS                                              = 16;
+
+// Viewflag Constants (use with R_SetView)
+const int              VF_MIN                                                  = 1;    //(vector)
+const int              VF_MIN_X                                                = 2;    //(float)
+const int              VF_MIN_Y                                                = 3;    //(float)
+const int              VF_SIZE                                                 = 4;    //(vector) (viewport size)
+const int              VF_SIZE_Y                                               = 5;    //(float)
+const int              VF_SIZE_X                                               = 6;    //(float)
+const int              VF_VIEWPORT                                             = 7;    //(vector, vector)
+const int              VF_FOV                                                  = 8;    //(vector)
+const int              VF_FOVX                                                 = 9;    //(float)
+const int              VF_FOVY                                                 = 10;   //(float)
+const int              VF_ORIGIN                                               = 11;   //(vector)
+const int              VF_ORIGIN_X                                             = 12;   //(float)
+const int              VF_ORIGIN_Y                                             = 13;   //(float)
+const int              VF_ORIGIN_Z                                             = 14;   //(float)
+const int              VF_ANGLES                                               = 15;   //(vector)
+const int              VF_ANGLES_X                                             = 16;   //(float)
+const int              VF_ANGLES_Y                                             = 17;   //(float)
+const int              VF_ANGLES_Z                                             = 18;   //(float)
+const int              VF_DRAWWORLD                                    = 19;   //(float)
+const int              VF_DRAWENGINEHUD                                = 20;   //(float)
+const int              VF_DRAWCROSSHAIR                                = 21;   //(float)
+const int              VF_PERSPECTIVE                                  = 200;  //(float)
+
+const int              VF_CL_VIEWANGLES                                = 33;   //(vector)
+const int              VF_CL_VIEWANGLES_X                              = 34;   //(float)
+const int              VF_CL_VIEWANGLES_Y                              = 35;   //(float)
+const int              VF_CL_VIEWANGLES_Z                              = 36;   //(float)
+
+// Quake-style Point Contents
+const int              CONTENT_EMPTY                                   = -1;
+const int              CONTENT_SOLID                                   = -2;
+const int              CONTENT_WATER                                   = -3;
+const int              CONTENT_SLIME                                   = -4;
+const int              CONTENT_LAVA                                    = -5;
+const int              CONTENT_SKY                                             = -6;
+
+// Vector / Hull Constants
+const vector   VEC_1                                                   = '1 1 1';
+const vector   VEC_0                                                   = '0 0 0';
+const vector   VEC_M1                                                  = '-1 -1 -1';
+
+const vector   VEC_HULL_MIN                                    = '-16 -16 -24';
+const vector   VEC_HULL_MAX                                    = '16 16 32';
+
+// Effect Constants
+const int      EF_NODRAW                                               = 16;
+const int      EF_ADDITIVE                                             = 32;
+const int      EF_BLUE                                                 = 64;
+const int      EF_RED                                                  = 128;
+const int      EF_FULLBRIGHT                                   = 512;
+const int      EF_FLAME                                                = 1024;
+const int      EF_STARDUST                                             = 2048;
+const int      EF_NOSHADOW                                             = 4096;
+const int      EF_NODEPTHTEST                                  = 8192;
+
+// Quake Player Flag Constants
+const int      PFL_ONGROUND                                    = 1;
+const int      PFL_CROUCH                                              = 2;
+const int      PFL_DEAD                                                = 4;
+const int      PFL_GIBBED                                              = 8;
+
+// Quake Temporary Entity Constants
+const int              TE_SPIKE                                                = 0;
+const int              TE_SUPERSPIKE                                   = 1;
+const int              TE_GUNSHOT                                              = 2;
+const int              TE_EXPLOSION                                    = 3;
+const int              TE_TAREXPLOSION                                 = 4;
+const int              TE_LIGHTNING1                                   = 5;
+const int              TE_LIGHTNING2                                   = 6;
+const int              TE_WIZSPIKE                                             = 7;
+const int              TE_KNIGHTSPIKE                                  = 8;
+const int              TE_LIGHTNING3                                   = 9;
+const int              TE_LAVASPLASH                                   = 10;
+const int              TE_TELEPORT                                             = 11;
+const int      TE_EXPLOSION2                                   = 12;
+// Darkplaces Additions
+const int      TE_EXPLOSIONRGB                                 = 53;
+const int              TE_GUNSHOTQUAD                                  = 57;
+const int              TE_EXPLOSIONQUAD                                = 70;
+
+// Math Constants
+const int      EXTRA_LOW                                               = -99999999;
+const int      EXTRA_HIGH                                              = 99999999;
+
+// Frik File Constants
+const int              FILE_READ                                               = 0;
+const int              FILE_APPEND                                             = 1;
+const int              FILE_WRITE                                              = 2;
+
+// Button values used by input_buttons
+const int BUTTON_ATTACK = 1;
+const int BUTTON_JUMP = 2;
+const int BUTTON_3 = 4;
+const int BUTTON_4 = 8;
+const int BUTTON_5 = 16;
+const int BUTTON_6 = 32;
+const int BUTTON7 = 64;
+const int BUTTON8 = 128;
+const int BUTTON_USE = 256;
+const int BUTTON_CHAT = 512;
+const int BUTTON_PRYDONCURSOR = 1024;
+const int BUTTON_9 = 2048;
+const int BUTTON_10 = 4096;
+const int BUTTON_11 = 8192;
+const int BUTTON_12 = 16384;
+const int BUTTON_13 = 32768;
+const int BUTTON_14 = 65536;
+const int BUTTON_15 = 131072;
+const int BUTTON_16 = 262144;
+
+const int SOLID_NOT            = 0; // no interaction with other objects
+const int SOLID_TRIGGER        = 1; // touch on edge, but not blocking
+const int SOLID_BBOX           = 2; // touch on edge, block
+const int SOLID_SLIDEBOX       = 3; // touch on edge, but not an onground
+const int SOLID_BSP            = 4; // bsp clip, touch on edge, block
+const int SOLID_CORPSE         = 5; // same as SOLID_BBOX, except it behaves as SOLID_NOT against SOLID_SLIDEBOX objects (players/monsters)
+
+const int MOVE_NORMAL = 0; // same as false
+const int MOVE_NOMONSTERS = 1; // same as true
+const int MOVE_MISSILE = 2; // save as movement with .movetype == MOVETYPE_FLYMISSILE
+const int MOVE_HITMODEL = 4;
+const int MOVE_WORLDONLY = 3;
+
+const int CAMERA_FREE = 1;
+const int CAMERA_CHASE = 2;
+
+const int EF_NOMODELFLAGS = 8388608;
+
+#endif
index 8003fd8b9b0d0b049741327152ac0af42939cfe2..f3437326365b87fe22d91b1250a90d7019e59498 100644 (file)
@@ -1,6 +1,7 @@
 #ifndef BUFFS_H
 #define BUFFS_H
 
 #ifndef BUFFS_H
 #define BUFFS_H
 
+#include "teams.qh"
 #include "util.qh"
 
 entity Buff_Type_first;
 #include "util.qh"
 
 entity Buff_Type_first;
index dda68d7913e314afee190d9f47367975fa2b128e..83526614ab5e3e7b6ec5e6f9f481797bb5c9df2c 100644 (file)
@@ -1,7 +1,6 @@
 #ifndef NOTIFICATIONS_H
 #define NOTIFICATIONS_H
 
 #ifndef NOTIFICATIONS_H
 #define NOTIFICATIONS_H
 
-#include "autocvars.qh"
 #include "constants.qh"
 #include "teams.qh"
 #include "util.qh"
 #include "constants.qh"
 #include "teams.qh"
 #include "util.qh"
index 4effe6492446b65192b91d838bebd11da4828c1b..136d7ca1d555a45222dc329ccc9753e93e0696b3 100644 (file)
@@ -267,8 +267,8 @@ const vector VEC_M1                         = '-1 -1 -1';
 
 //const float M_PI                             = 3.14159265358979323846;
 
 
 //const float M_PI                             = 3.14159265358979323846;
 
-vector VEC_HULL_MIN                            = '-16 -16 -24';
-vector VEC_HULL_MAX                            = '16 16 32';
+const vector VEC_HULL_MIN              = '-16 -16 -24';
+const vector VEC_HULL_MAX              = '16 16 32';
 
 // Quake Temporary Entity Constants
 const int TE_SPIKE                             = 0;
 
 // Quake Temporary Entity Constants
 const int TE_SPIKE                             = 0;
@@ -1083,7 +1083,7 @@ float PRECACHE_PIC_MIPMAP = 8; // mipmap the texture for possibly better downsca
 //idea: LordHavoc
 //darkplaces implementation: LordHavoc
 //constant definitions:
 //idea: LordHavoc
 //darkplaces implementation: LordHavoc
 //constant definitions:
-float MOVE_WORLDONLY = 3;
+const float MOVE_WORLDONLY = 3;
 //description:
 //allows traces to hit only world (ignoring all entities, unlike MOVE_NOMONSTERS which hits all bmodels), use as the nomonsters parameter to trace functions
 
 //description:
 //allows traces to hit only world (ignoring all entities, unlike MOVE_NOMONSTERS which hits all bmodels), use as the nomonsters parameter to trace functions
 
index 109e9195bb03cda7212ef627a29fbe8cd5785e4c..47fdcc18053b5d24a90018904cacb0c3af6fff9a 100644 (file)
@@ -1132,7 +1132,7 @@ float MOVE_HITMODEL = 4;
 //idea: LordHavoc
 //darkplaces implementation: LordHavoc
 //constant definitions:
 //idea: LordHavoc
 //darkplaces implementation: LordHavoc
 //constant definitions:
-float MOVE_WORLDONLY = 3;
+const float MOVE_WORLDONLY = 3;
 //description:
 //allows traces to hit only world (ignoring all entities, unlike MOVE_NOMONSTERS which hits all bmodels), use as the nomonsters parameter to trace functions
 
 //description:
 //allows traces to hit only world (ignoring all entities, unlike MOVE_NOMONSTERS which hits all bmodels), use as the nomonsters parameter to trace functions
 
diff --git a/qcsrc/server/_.qh b/qcsrc/server/_.qh
new file mode 100644 (file)
index 0000000..6438a10
--- /dev/null
@@ -0,0 +1,12 @@
+#ifndef SERVER___H
+#define SERVER___H
+
+#include "autocvars.qh"
+#include "constants.qh"
+#include "defs.qh"
+#include "miscfunctions.qh"
+
+#include "../dpdefs/progsdefs.qh"
+#include "../dpdefs/dpextensions.qh"
+
+#endif
index b529ed1c32f2899650b7dd498024f2b5b6bb0929..b68fc6c1aee8e083bb947f154b385079187e777b 100644 (file)
@@ -1,3 +1,9 @@
+#include "aim.qh"
+#include "../_.qh"
+
+#include "bot.qh"
+
+#include "../mutators/mutators_include.qh"
 
 // traces multiple trajectories to find one that will impact the target
 // 'end' vector is the place it aims for,
 
 // traces multiple trajectories to find one that will impact the target
 // 'end' vector is the place it aims for,
index fb191a91cce7e61f9f0c930d78c85a988bfd979b..d1cbd0d629a71368ed5b8ea74fe26b4a73ea245d 100644 (file)
@@ -86,6 +86,7 @@ vector shotdir;
  * Functions
  */
 
  * Functions
  */
 
+float lag_additem(float t, float f1, float f2, entity e1, vector v1, vector v2, vector v3, vector v4);
 void lag_update();
 void bot_lagfunc(float t, float f1, float f2, entity e1, vector v1, vector v2, vector v3, vector v4);
 
 void lag_update();
 void bot_lagfunc(float t, float f1, float f2, entity e1, vector v1, vector v2, vector v3, vector v4);
 
index 0acd32993595139f9a777ba74b527a1c574ee7a2..068ca61efe94e1e6daadc8ec266a91cfeb14d46c 100644 (file)
@@ -1,37 +1,41 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../warpzonelib/common.qh"
-    #include "../../warpzonelib/util_server.qh"
-    #include "../../common/constants.qh"
-    #include "../../common/teams.qh"
-    #include "../../common/util.qh"
-    #include "../../common/weapons/weapons.qh"
-    #include "../weapons/accuracy.qh"
-    #include "../t_items.qh"
-    #include "../autocvars.qh"
-    #include "../constants.qh"
-    #include "../defs.qh"
-    #include "../mutators/mutators_include.qh"
-    #include "../campaign.qh"
-    #include "../../common/mapinfo.qh"
-    #include "../../csqcmodellib/sv_model.qh"
-    #include "../antilag.qh"
-#endif
-
 #include "bot.qh"
 #include "bot.qh"
+#include "../_.qh"
+
 #include "aim.qh"
 #include "navigation.qh"
 #include "aim.qh"
 #include "navigation.qh"
+#include "scripting.qh"
 #include "waypoints.qh"
 
 #include "waypoints.qh"
 
-#include "aim.qc"
-#include "navigation.qc"
-#include "waypoints.qc"
-#include "scripting.qc"
+#include "havocbot/havocbot.qh"
+#include "havocbot/scripting.qh"
+
+#include "../antilag.qh"
+#include "../autocvars.qh"
+#include "../campaign.qh"
+#include "../cl_client.qh"
+#include "../constants.qh"
+#include "../defs.qh"
+#include "../race.qh"
+#include "../t_items.qh"
+
+#include "../mutators/mutators_include.qh"
+
+#include "../weapons/accuracy.qh"
+
+#include "../../common/constants.qh"
+#include "../../common/mapinfo.qh"
+#include "../../common/teams.qh"
+#include "../../common/util.qh"
+
+#include "../../common/weapons/weapons.qh"
+
+#include "../../csqcmodellib/sv_model.qh"
+
+#include "../../dpdefs/dpextensions.qh"
+#include "../../dpdefs/progsdefs.qh"
 
 
-#include "havocbot/havocbot.qc"
+#include "../../warpzonelib/common.qh"
+#include "../../warpzonelib/util_server.qh"
 
 entity bot_spawn()
 {
 
 entity bot_spawn()
 {
index bcae58dc181e0c89b9db7ef02e729d2660516e04..ac89f06a7382dc91aec1d68427af2b4b0a6269c1 100644 (file)
@@ -91,6 +91,7 @@ float bot_ignore_bots; // let bots not attack other bots (only works in non-team
  */
 
 entity bot_spawn();
  */
 
 entity bot_spawn();
+float bot_fixcount();
 
 void bot_think();
 void bot_setnameandstuff();
 
 void bot_think();
 void bot_setnameandstuff();
index f05df2886a5509d19fbafc98d5b09fbfdeee3591..687dcf5fe170f222d59251d25074edaab9060bcb 100644 (file)
@@ -1,8 +1,15 @@
 #include "havocbot.qh"
 #include "havocbot.qh"
+#include "../../_.qh"
 
 
-#include "role_onslaught.qc"
-#include "role_keyhunt.qc"
-#include "roles.qc"
+#include "../aim.qh"
+#include "../bot.qh"
+#include "../navigation.qh"
+#include "../scripting.qh"
+#include "../waypoints.qh"
+
+#include "../../../common/constants.qh"
+
+#include "../../../warpzonelib/common.qh"
 
 void havocbot_ai()
 {
 
 void havocbot_ai()
 {
index 3b641d9ce757762c430d03be58e9b4e948dc90ea..6b4b1012ac70eefd4328192df9b9cfdc9f91cf02 100644 (file)
@@ -1,10 +1,18 @@
+#include "role_keyhunt.qh"
+#include "../../_.qh"
+
+#include "havocbot.qh"
+
+#include "../bot.qh"
+#include "../navigation.qh"
+
+#include "../../mutators/mutators_include.qh"
+
 void() havocbot_role_kh_carrier;
 void() havocbot_role_kh_defense;
 void() havocbot_role_kh_offense;
 void() havocbot_role_kh_freelancer;
 
 void() havocbot_role_kh_carrier;
 void() havocbot_role_kh_defense;
 void() havocbot_role_kh_offense;
 void() havocbot_role_kh_freelancer;
 
-entity kh_worldkeylist;
-.entity kh_worldkeynext;
 
 void havocbot_goalrating_kh(float ratingscale_team, float ratingscale_dropped, float ratingscale_enemy)
 {
 
 void havocbot_goalrating_kh(float ratingscale_team, float ratingscale_dropped, float ratingscale_enemy)
 {
diff --git a/qcsrc/server/bot/havocbot/role_keyhunt.qh b/qcsrc/server/bot/havocbot/role_keyhunt.qh
new file mode 100644 (file)
index 0000000..f3136c6
--- /dev/null
@@ -0,0 +1,8 @@
+#ifndef ROLE_KEYHUNT_H
+#define ROLE_KEYHUNT_H
+
+entity kh_worldkeylist;
+.entity kh_worldkeynext;
+
+void havocbot_chooserole_kh();
+#endif
index 119ea83c81b77c90b659518bf03a601d49f2f360..13c9cdc0312b30984db78b499026f242cc17571e 100644 (file)
@@ -1,3 +1,15 @@
+#include "../../_.qh"
+
+#include "havocbot.qh"
+
+#include "../bot.qh"
+#include "../navigation.qh"
+#include "../waypoints.qh"
+
+#include "../../mutators/mutators_include.qh"
+
+#include "../../../common/teams.qh"
+
 const int HAVOCBOT_ONS_ROLE_NONE               = 0;
 const int HAVOCBOT_ONS_ROLE_DEFENSE    = 2;
 const int HAVOCBOT_ONS_ROLE_ASSISTANT  = 4;
 const int HAVOCBOT_ONS_ROLE_NONE               = 0;
 const int HAVOCBOT_ONS_ROLE_DEFENSE    = 2;
 const int HAVOCBOT_ONS_ROLE_ASSISTANT  = 4;
diff --git a/qcsrc/server/bot/havocbot/role_onslaught.qh b/qcsrc/server/bot/havocbot/role_onslaught.qh
new file mode 100644 (file)
index 0000000..3fca678
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef ROLE_ONSLAUGHT_H
+#define ROLE_ONSLAUGHT_H
+void havocbot_chooserole_ons();
+#endif
index af219b8ec730272f85f334402ea9c8cc4dc229f4..2f1a8d7196fe739675ed4a44501255ae833287d9 100644 (file)
@@ -1,3 +1,11 @@
+#include "../../_.qh"
+
+#include "havocbot.qh"
+#include "role_keyhunt.qh"
+#include "role_onslaught.qh"
+
+#include "../bot.qh"
+#include "../navigation.qh"
 
 .float max_armorvalue;
 .float havocbot_role_timeout;
 
 .float max_armorvalue;
 .float havocbot_role_timeout;
diff --git a/qcsrc/server/bot/havocbot/roles.qh b/qcsrc/server/bot/havocbot/roles.qh
new file mode 100644 (file)
index 0000000..cfabf05
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef ROLES_H
+#define ROLES_H
+void havocbot_goalrating_controlpoints(float ratingscale, vector org, float sradius);
+#endif
diff --git a/qcsrc/server/bot/havocbot/scripting.qh b/qcsrc/server/bot/havocbot/scripting.qh
new file mode 100644 (file)
index 0000000..c09dbde
--- /dev/null
@@ -0,0 +1,5 @@
+#ifndef HAVOCBOT_SCRIPTING_H
+#define HAVOCBOT_SCRIPTING_H
+
+void bot_clearqueue(entity bot);
+#endif
index d80f8336c8ba179bd52e862bc2807181d92efebc..018a6eb06ddf76151892b8234b5b5d5d999aa31c 100644 (file)
@@ -1,3 +1,13 @@
+#include "navigation.qh"
+#include "../_.qh"
+
+#include "bot.qh"
+#include "waypoints.qh"
+
+#include "../t_items.qh"
+
+#include "../../common/constants.qh"
+
 void bot_debug(string input)
 {
        switch(autocvar_bot_debug)
 void bot_debug(string input)
 {
        switch(autocvar_bot_debug)
index 08e1c53ac88d4fb8304076157bd4a95e88ea8f9b..cf4a5ce5b261dcf6c4e154bef405c480d85a2afb 100644 (file)
@@ -76,4 +76,5 @@ void navigation_unstuck();
 void botframe_updatedangerousobjects(float maxupdate);
 
 entity navigation_findnearestwaypoint(entity ent, float walkfromwp);
 void botframe_updatedangerousobjects(float maxupdate);
 
 entity navigation_findnearestwaypoint(entity ent, float walkfromwp);
+float navigation_waypoint_will_link(vector v, vector org, entity ent, float walkfromwp, float bestdist);
 #endif
 #endif
index c9a86d56a54c78ea95076ef864fe71dc4328acfa..6aedb6040e9c58860a19132aa640c67dd51db581 100644 (file)
@@ -1,3 +1,8 @@
+#include "scripting.qh"
+#include "../_.qh"
+
+#include "bot.qh"
+
 .float bot_cmdqueuebuf_allocated;
 .float bot_cmdqueuebuf;
 .float bot_cmdqueuebuf_start;
 .float bot_cmdqueuebuf_allocated;
 .float bot_cmdqueuebuf;
 .float bot_cmdqueuebuf_start;
@@ -137,68 +142,6 @@ entity bot_getplace(string placename)
 }
 
 
 }
 
 
-// NOTE: New commands should be added here. Do not forget to update BOT_CMD_COUNTER
-const int BOT_CMD_NULL                         = 0;
-const int BOT_CMD_PAUSE                = 1;
-const int BOT_CMD_CONTINUE             = 2;
-const int BOT_CMD_WAIT                         = 3;
-const int BOT_CMD_TURN                         = 4;
-const int BOT_CMD_MOVETO               = 5;
-const int BOT_CMD_RESETGOAL    = 6;    // Not implemented yet
-const int BOT_CMD_CC                   = 7;
-const int BOT_CMD_IF                   = 8;
-const int BOT_CMD_ELSE                         = 9;
-const int BOT_CMD_FI                   = 10;
-const int BOT_CMD_RESETAIM             = 11;
-const int BOT_CMD_AIM                  = 12;
-const int BOT_CMD_PRESSKEY             = 13;
-const int BOT_CMD_RELEASEKEY   = 14;
-const int BOT_CMD_SELECTWEAPON         = 15;
-const int BOT_CMD_IMPULSE              = 16;
-const int BOT_CMD_WAIT_UNTIL   = 17;
-const int BOT_CMD_MOVETOTARGET         = 18;
-const int BOT_CMD_AIMTARGET    = 19;
-const int BOT_CMD_BARRIER              = 20;
-const int BOT_CMD_CONSOLE              = 21;
-const int BOT_CMD_SOUND                = 22;
-const int BOT_CMD_DEBUG_ASSERT_CANFIRE = 23;
-const int BOT_CMD_WHILE                = 24;   // TODO: Not implemented yet
-const int BOT_CMD_WEND                         = 25;   // TODO: Not implemented yet
-const int BOT_CMD_CHASE                = 26;   // TODO: Not implemented yet
-
-const int BOT_CMD_COUNTER              = 24;   // Update this value if you add/remove a command
-
-// NOTE: Following commands should be implemented on the bot ai
-//              If a new command should be handled by the target ai(s) please declare it here
-.float(vector) cmd_moveto;
-.float() cmd_resetgoal;
-
-//
-const int BOT_CMD_PARAMETER_NONE = 0;
-const int BOT_CMD_PARAMETER_FLOAT = 1;
-const int BOT_CMD_PARAMETER_STRING = 2;
-const int BOT_CMD_PARAMETER_VECTOR = 3;
-
-float bot_cmds_initialized;
-int bot_cmd_parm_type[BOT_CMD_COUNTER];
-string bot_cmd_string[BOT_CMD_COUNTER];
-
-// Bots command queue
-entity bot_cmd;        // global current command
-.entity bot_cmd_current; // current command of this bot
-
-.float is_bot_cmd;                     // Tells if the entity is a bot command
-.float bot_cmd_index;                  // Position of the command in the queue
-.int bot_cmd_type;                     // If of command (see the BOT_CMD_* defines)
-.float bot_cmd_parm_float;             // Field to store a float parameter
-.string bot_cmd_parm_string;           // Field to store a string parameter
-.vector bot_cmd_parm_vector;           // Field to store a vector parameter
-
-float bot_barriertime;
-.float bot_barrier;
-
-.float bot_cmd_execution_index;                // Position in the queue of the command to be executed
-
 // Initialize global commands list
 // NOTE: New commands should be initialized here
 void bot_commands_init()
 // Initialize global commands list
 // NOTE: New commands should be initialized here
 void bot_commands_init()
@@ -529,14 +472,6 @@ void bot_list_commands()
 // Commands code
 .int bot_exec_status;
 
 // Commands code
 .int bot_exec_status;
 
-#define BOT_EXEC_STATUS_IDLE   0
-#define BOT_EXEC_STATUS_PAUSED 1
-#define BOT_EXEC_STATUS_WAITING        2
-
-#define CMD_STATUS_EXECUTING   0
-#define CMD_STATUS_FINISHED    1
-#define CMD_STATUS_ERROR       2
-
 void SV_ParseClientCommand(string s);
 float bot_cmd_cc()
 {
 void SV_ParseClientCommand(string s);
 float bot_cmd_cc()
 {
diff --git a/qcsrc/server/bot/scripting.qh b/qcsrc/server/bot/scripting.qh
new file mode 100644 (file)
index 0000000..d5cdda9
--- /dev/null
@@ -0,0 +1,83 @@
+#ifndef BOT_SCRIPTING_H
+#define BOT_SCRIPTING_H
+
+#define BOT_EXEC_STATUS_IDLE 0
+#define BOT_EXEC_STATUS_PAUSED 1
+#define BOT_EXEC_STATUS_WAITING 2
+
+#define CMD_STATUS_EXECUTING 0
+#define CMD_STATUS_FINISHED 1
+#define CMD_STATUS_ERROR 2
+
+
+// NOTE: New commands should be added here. Do not forget to update BOT_CMD_COUNTER
+const int BOT_CMD_NULL                         = 0;
+const int BOT_CMD_PAUSE                = 1;
+const int BOT_CMD_CONTINUE             = 2;
+const int BOT_CMD_WAIT                         = 3;
+const int BOT_CMD_TURN                         = 4;
+const int BOT_CMD_MOVETO               = 5;
+const int BOT_CMD_RESETGOAL    = 6;    // Not implemented yet
+const int BOT_CMD_CC                   = 7;
+const int BOT_CMD_IF                   = 8;
+const int BOT_CMD_ELSE                         = 9;
+const int BOT_CMD_FI                   = 10;
+const int BOT_CMD_RESETAIM             = 11;
+const int BOT_CMD_AIM                  = 12;
+const int BOT_CMD_PRESSKEY             = 13;
+const int BOT_CMD_RELEASEKEY   = 14;
+const int BOT_CMD_SELECTWEAPON         = 15;
+const int BOT_CMD_IMPULSE              = 16;
+const int BOT_CMD_WAIT_UNTIL   = 17;
+const int BOT_CMD_MOVETOTARGET         = 18;
+const int BOT_CMD_AIMTARGET    = 19;
+const int BOT_CMD_BARRIER              = 20;
+const int BOT_CMD_CONSOLE              = 21;
+const int BOT_CMD_SOUND                = 22;
+const int BOT_CMD_DEBUG_ASSERT_CANFIRE = 23;
+const int BOT_CMD_WHILE                = 24;   // TODO: Not implemented yet
+const int BOT_CMD_WEND                         = 25;   // TODO: Not implemented yet
+const int BOT_CMD_CHASE                = 26;   // TODO: Not implemented yet
+
+const int BOT_CMD_COUNTER              = 24;   // Update this value if you add/remove a command
+
+// NOTE: Following commands should be implemented on the bot ai
+//              If a new command should be handled by the target ai(s) please declare it here
+.float(vector) cmd_moveto;
+.float() cmd_resetgoal;
+
+//
+const int BOT_CMD_PARAMETER_NONE = 0;
+const int BOT_CMD_PARAMETER_FLOAT = 1;
+const int BOT_CMD_PARAMETER_STRING = 2;
+const int BOT_CMD_PARAMETER_VECTOR = 3;
+
+float bot_cmds_initialized;
+int bot_cmd_parm_type[BOT_CMD_COUNTER];
+string bot_cmd_string[BOT_CMD_COUNTER];
+
+// Bots command queue
+entity bot_cmd;        // global current command
+.entity bot_cmd_current; // current command of this bot
+
+.float is_bot_cmd;                     // Tells if the entity is a bot command
+.float bot_cmd_index;                  // Position of the command in the queue
+.int bot_cmd_type;                     // If of command (see the BOT_CMD_* defines)
+.float bot_cmd_parm_float;             // Field to store a float parameter
+.string bot_cmd_parm_string;           // Field to store a string parameter
+.vector bot_cmd_parm_vector;           // Field to store a vector parameter
+
+float bot_barriertime;
+.float bot_barrier;
+
+.float bot_cmd_execution_index;                // Position in the queue of the command to be executed
+
+
+void bot_resetqueues();
+void bot_queuecommand(entity bot, string cmdstring);
+void bot_cmdhelp(string scmd);
+void bot_list_commands();
+float bot_execute_commands();
+entity find_bot_by_name(string name);
+entity find_bot_by_number(float number);
+#endif
index 9d78cedc5bbcdaa814a17d8da2837236dc40e45c..8cd7ef3f505acd0be9de84e5de576ab8647f4e2e 100644 (file)
@@ -1,3 +1,15 @@
+#include "waypoints.qh"
+#include "../_.qh"
+
+#include "bot.qh"
+#include "navigation.qh"
+
+#include "../antilag.qh"
+
+#include "../../common/constants.qh"
+
+#include "../../warpzonelib/util_server.qh"
+
 // create a new spawnfunc_waypoint and automatically link it to other waypoints, and link
 // them back to it as well
 // (suitable for spawnfunc_waypoint editor)
 // create a new spawnfunc_waypoint and automatically link it to other waypoints, and link
 // them back to it as well
 // (suitable for spawnfunc_waypoint editor)
index 657ec4d7fd3c0e15f6477c5a56c766b5a5effcb1..d1e72a5ec421ee84515817bb41a73ff652ec81eb 100644 (file)
@@ -1,26 +1,26 @@
 #include "cheats.qh"
 #include "cheats.qh"
+#include "_.qh"
+
 #include "g_damage.qh"
 #include "race.qh"
 #include "t_teleporters.qh"
 
 #include "g_damage.qh"
 #include "race.qh"
 #include "t_teleporters.qh"
 
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/anglestransform.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/tracing.qh"
-    #include "autocvars.qh"
-    #include "defs.qh"
-    #include "../common/deathtypes.qh"
-    #include "mutators/mutators_include.qh"
-    #include "../csqcmodellib/sv_model.qh"
-#endif
+#include "mutators/mutators_include.qh"
+
+#include "weapons/tracing.qh"
+
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/util.qh"
+
+#include "../common/monsters/monsters.qh"
+
+#include "../common/weapons/weapons.qh"
+
+#include "../csqcmodellib/sv_model.qh"
+
+#include "../warpzonelib/anglestransform.qh"
+#include "../warpzonelib/util_server.qh"
 
 void CopyBody(float keepvelocity);
 
 
 void CopyBody(float keepvelocity);
 
@@ -40,15 +40,7 @@ void Drag_MoveDrag(entity from, entity to) { }
 .float maycheat;
 float gamestart_sv_cheats;
 
 .float maycheat;
 float gamestart_sv_cheats;
 
-const float CHIMPULSE_SPEEDRUN_INIT = 30;
-const float CHIMPULSE_GIVE_ALL = 99;
-const float CHIMPULSE_CLONE_MOVING = 140;
-const float CHIMPULSE_SPEEDRUN = 141;
-const float CHIMPULSE_CLONE_STANDING = 142;
-const float CHIMPULSE_TELEPORT = 143;
-const float CHIMPULSE_R00T = 148;
 
 
-const float CHRAME_DRAG = 8;
 
 void CheatInit()
 {
 
 void CheatInit()
 {
index 625a304bd51f99ce3539942cd58d5a47f3c4aff3..f200c4c867bc5afc73e7c3eb86483a38e7f621ed 100644 (file)
@@ -13,5 +13,15 @@ float CheatImpulse(float i);
 float CheatCommand(float argc);
 float CheatFrame();
 
 float CheatCommand(float argc);
 float CheatFrame();
 
+const float CHIMPULSE_SPEEDRUN_INIT = 30;
+const float CHIMPULSE_GIVE_ALL = 99;
+const float CHIMPULSE_CLONE_MOVING = 140;
+const float CHIMPULSE_SPEEDRUN = 141;
+const float CHIMPULSE_CLONE_STANDING = 142;
+const float CHIMPULSE_TELEPORT = 143;
+const float CHIMPULSE_R00T = 148;
+
+const float CHRAME_DRAG = 8;
+
 void Drag_MoveDrag(entity from, entity to); // call this from CopyBody
 #endif
 void Drag_MoveDrag(entity from, entity to); // call this from CopyBody
 #endif
index c0a8bde5180fd2a0c81f6544fd74928c17e9b5a2..61565b7674c043930e31ef7e7cc45cd41f3c723e 100644 (file)
@@ -1,5 +1,8 @@
+#include "cl_client.qh"
+
 #include "waypointsprites.qh"
 
 #include "waypointsprites.qh"
 
+#include "anticheat.qh"
 #include "cl_impulse.qh"
 #include "cl_player.qh"
 #include "ent_cs.qh"
 #include "cl_impulse.qh"
 #include "cl_player.qh"
 #include "ent_cs.qh"
 #include "teamplay.qh"
 #include "playerdemo.qh"
 #include "secret.qh"
 #include "teamplay.qh"
 #include "playerdemo.qh"
 #include "secret.qh"
+#include "spawnpoints.qh"
+#include "g_damage.qh"
+#include "g_hook.qh"
+#include "t_teleporters.qh"
+#include "command/common.qh"
+#include "cheats.qh"
+#include "g_world.qh"
+#include "race.qh"
+#include "antilag.qh"
+#include "campaign.qh"
+#include "command/common.qh"
 
 #include "bot/bot.qh"
 #include "bot/navigation.qh"
 
 
 #include "bot/bot.qh"
 #include "bot/navigation.qh"
 
+#include "vehicles/vehicles_def.qh"
+
 #include "weapons/hitplot.qh"
 #include "weapons/weaponsystem.qh"
 
 #include "weapons/hitplot.qh"
 #include "weapons/weaponsystem.qh"
 
@@ -23,7 +39,6 @@
 
 #include "../warpzonelib/server.qh"
 
 
 #include "../warpzonelib/server.qh"
 
-float c1, c2, c3, c4;
 
 void send_CSQC_teamnagger() {
        WriteByte(MSG_BROADCAST, SVC_TEMPENTITY);
 
 void send_CSQC_teamnagger() {
        WriteByte(MSG_BROADCAST, SVC_TEMPENTITY);
diff --git a/qcsrc/server/cl_client.qh b/qcsrc/server/cl_client.qh
new file mode 100644 (file)
index 0000000..213a029
--- /dev/null
@@ -0,0 +1,13 @@
+#ifndef CL_CLIENT_H
+#define CL_CLIENT_H
+float c1, c2, c3, c4;
+
+void play_countdown(float finished, string samp);
+
+float CalcRotRegen(float current, float regenstable, float regenfactor, float regenlinear, float regenframetime, float rotstable, float rotfactor, float rotlinear, float rotframetime, float limit);
+
+float Spectate(entity pl);
+
+void CTS_ClientKill (entity e);
+
+#endif
index b65a660f0a46d2ec6a7967f94778046d25cb430d..8b40f9cf94c9bca7cc456e7c6cb1fdd116c0a0dc 100644 (file)
@@ -1,8 +1,17 @@
+#include "_.qh"
 #include "round_handler.qh"
 
 #include "bot/waypoints.qh"
 
 #include "weapons/throwing.qh"
 #include "round_handler.qh"
 
 #include "bot/waypoints.qh"
 
 #include "weapons/throwing.qh"
+#include "command/common.qh"
+#include "cheats.qh"
+#include "bot/navigation.qh"
+#include "weapons/selection.qh"
+#include "weapons/tracing.qh"
+#include "weapons/weaponsystem.qh"
+#include "vehicles/vehicles_def.qh"
+#include "waypointsprites.qh"
 
 #include "../common/weapons/weapons.qh"
 
 
 #include "../common/weapons/weapons.qh"
 
index 337342333c0b0230b6d2362d5c1a4119b79d350a..40552899a0bf01c5e001993da8f713a95ab10152 100644 (file)
@@ -1,3 +1,7 @@
+#include "_.qh"
+#include "bot/bot.qh"
+#include "g_damage.qh"
+
 #if defined(CSQC)
 #elif defined(MENUQC)
 #elif defined(SVQC)
 #if defined(CSQC)
 #elif defined(MENUQC)
 #elif defined(SVQC)
@@ -659,32 +663,6 @@ void SpecialCommand()
 #endif
 }
 
 #endif
 }
 
-float speedaward_speed;
-string speedaward_holder;
-string speedaward_uid;
-void race_send_speedaward(float msg)
-{
-       // send the best speed of the round
-       WriteByte(msg, SVC_TEMPENTITY);
-       WriteByte(msg, TE_CSQC_RACE);
-       WriteByte(msg, RACE_NET_SPEED_AWARD);
-       WriteInt24_t(msg, floor(speedaward_speed+0.5));
-       WriteString(msg, speedaward_holder);
-}
-
-float speedaward_alltimebest;
-string speedaward_alltimebest_holder;
-string speedaward_alltimebest_uid;
-void race_send_speedaward_alltimebest(float msg)
-{
-       // send the best speed
-       WriteByte(msg, SVC_TEMPENTITY);
-       WriteByte(msg, TE_CSQC_RACE);
-       WriteByte(msg, RACE_NET_SPEED_AWARD_BEST);
-       WriteInt24_t(msg, floor(speedaward_alltimebest+0.5));
-       WriteString(msg, speedaward_alltimebest_holder);
-}
-
 string GetMapname(void);
 float speedaward_lastupdate;
 float speedaward_lastsent;
 string GetMapname(void);
 float speedaward_lastupdate;
 float speedaward_lastsent;
index 416fb1db7dc98dd70604cd61ec94add8b1961d99..ce03dfa989fdbeabc24cbd424f7ac1e0fe2b800b 100644 (file)
@@ -1,7 +1,23 @@
 #include "cl_player.qh"
 #include "cl_player.qh"
+#include "_.qh"
+
+#include "bot/bot.qh"
+#include "cheats.qh"
+#include "g_damage.qh"
+#include "g_subs.qh"
 #include "g_triggers.qh"
 #include "g_violence.qh"
 #include "miscfunctions.qh"
 #include "g_triggers.qh"
 #include "g_violence.qh"
 #include "miscfunctions.qh"
+#include "portals.qh"
+#include "teamplay.qh"
+#include "waypointsprites.qh"
+#include "weapons/throwing.qh"
+#include "command/common.qh"
+#include "../common/animdecide.qh"
+#include "../common/csqcmodel_settings.qh"
+#include "../common/deathtypes.qh"
+#include "../common/playerstats.qh"
+#include "../csqcmodellib/sv_model.qh"
 
 #include "weapons/weaponstats.qh"
 
 
 #include "weapons/weaponstats.qh"
 
index 9091ae0b783b65953aa4abef156b4e3203ce8040..b696651171a61cc5e3f11f8dadcf4b647feec319 100644 (file)
@@ -1,14 +1,14 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/dpextensions.qh"
-    #include "../../common/util.qh"
-    #include "../../common/command/shared_defs.qh"
-    #include "../autocvars.qh"
-    #include "common.qh"
-    #include "banning.qh"
-    #include "../ipban.qh"
-#endif
+#include "../_.qh"
+#include "../cl_player.qh"
+
+#include "banning.qh"
+#include "common.qh"
+
+#include "../ipban.qh"
+
+#include "../../common/command/shared_defs.qh"
+
+#include "../../common/util.qh"
 // =====================================================
 //  Banning and kicking command code, written by Samual
 //  Last updated: December 29th, 2011
 // =====================================================
 //  Banning and kicking command code, written by Samual
 //  Last updated: December 29th, 2011
index 70daacc87ea98d6152b183dc6ea97b6fc0b30ef2..17eca95c738363e4c83c3fbe57d0762fd143111c 100644 (file)
@@ -16,4 +16,8 @@ float Ban_Delete(float i);
 
 // used by common/command/generic.qc:GenericCommand_dumpcommands to list all commands into a .txt file
 void BanCommand_macro_write_aliases(float fh);
 
 // used by common/command/generic.qc:GenericCommand_dumpcommands to list all commands into a .txt file
 void BanCommand_macro_write_aliases(float fh);
+
+void BanCommand_macro_help();
+float BanCommand_macro_usage(float argc);
+
 #endif
 #endif
index 14e0f201c0f7bb029d4f4363a8ba50e7b7ea39c3..d0913074344a0946da74a8348f5f0adeeb968343 100644 (file)
@@ -1,31 +1,41 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../warpzonelib/common.qh"
-    #include "../../common/constants.qh"
-    #include "../../common/teams.qh"
-    #include "../../common/util.qh"
-    #include "../../common/command/shared_defs.qh"
-    #include "../../common/monsters/monsters.qh"
-    #include "../../common/monsters/sv_monsters.qh"
-    #include "../../common/monsters/spawn.qh"
-    #include "../autocvars.qh"
-    #include "../defs.qh"
-    #include "../../common/notifications.qh"
-    #include "../../common/deathtypes.qh"
-    #include "../mutators/mutators_include.qh"
-    #include "../vehicles/vehicles_def.qh"
-    #include "../campaign.qh"
-    #include "../../common/mapinfo.qh"
-    #include "common.qh"
-    #include "vote.qh"
-    #include "cmd.qh"
-    #include "../cheats.qh"
-    #include "../scores.qh"
-    #include "../ipban.qh"
-#endif
+#include "cmd.qh"
+#include "../_.qh"
+
+#include "common.qh"
+#include "vote.qh"
+
+#include "../campaign.qh"
+#include "../cheats.qh"
+#include "../cl_player.qh"
+#include "../g_triggers.qh"
+#include "../ipban.qh"
+#include "../mapvoting.qh"
+#include "../scores.qh"
+#include "../teamplay.qh"
+
+#include "../mutators/mutators_include.qh"
+
+#include "../vehicles/vehicles_def.qh"
+
+#include "../../common/constants.qh"
+#include "../../common/deathtypes.qh"
+#include "../../common/mapinfo.qh"
+#include "../../common/notifications.qh"
+#include "../../common/teams.qh"
+#include "../../common/util.qh"
+
+#include "../../common/monsters/monsters.qh"
+#include "../../common/monsters/spawn.qh"
+#include "../../common/monsters/sv_monsters.qh"
+
+#include "../../common/command/shared_defs.qh"
+
+#include "../../dpdefs/dpextensions.qh"
+#include "../../dpdefs/progsdefs.qh"
+
+#include "../../warpzonelib/common.qh"
+
+void ClientKill_TeamChange (float targetteam); // 0 = don't change, -1 = auto, -2 = spec
 
 // =========================================================
 //  Server side networked commands code, reworked by Samual
 
 // =========================================================
 //  Server side networked commands code, reworked by Samual
index 5b7e761b7879077a18d841119ca0e0e2e4092c93..3fcb0a3f7e8ad7dff39748280833e22567ee230b 100644 (file)
@@ -1,5 +1,9 @@
 #include "common.qh"
 #include "common.qh"
+#include "../_.qh"
 
 
+#include "../scores.qh"
+
+#include "../../common/notifications.qh"
 #include "../../common/counting.qh"
 
 
 #include "../../common/counting.qh"
 
 
index aa8efd6d69a15934416371d6066b76c419bfc212..38c4bf16cac33e11779ad0d85219267e4b869a36 100644 (file)
@@ -1,17 +1,14 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../common/constants.qh"
-    #include "../../common/util.qh"
-    #include "../../common/counting.qh"
-    #include "../../common/monsters/monsters.qh"
-    #include "../defs.qh"
-    #include "../../common/mapinfo.qh"
-    #include "getreplies.qh"
-    #include "../race.qh"
-#endif
+#include "getreplies.qh"
+#include "../_.qh"
+
+#include "../race.qh"
+
+#include "../../common/constants.qh"
+#include "../../common/counting.qh"
+#include "../../common/mapinfo.qh"
+#include "../../common/util.qh"
+
+#include "../../common/monsters/monsters.qh"
 
 // =========================================================
 //  Reply messages for common commands, re-worked by Samual
 
 // =========================================================
 //  Reply messages for common commands, re-worked by Samual
index befbd1a8c58a7a358508c4d0c85cb712a059cfdf..792aba112ecb49e3d3dceddb4b6371b102b99a2b 100644 (file)
@@ -1,13 +1,12 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../common/util.qh"
-    #include "../defs.qh"
-    #include "radarmap.qh"
-    #include "../../csqcmodellib/sv_model.qh"
-#endif
+#include "radarmap.qh"
+#include "../_.qh"
+
+#include "../g_subs.qh"
+#include "../g_world.qh"
+
+#include "../../common/util.qh"
+
+#include "../../csqcmodellib/sv_model.qh"
 
 // ===============================================
 //     Generates radar map images for use in the HUD
 
 // ===============================================
 //     Generates radar map images for use in the HUD
index c2b068c7d1a9f2a01e86f8dcf9b5531ab2fc702d..fea60ba9e1143238181d3f5a131ea7034edcb3f7 100644 (file)
@@ -14,4 +14,8 @@ float sharpen_buffer[RADAR_WIDTH_MAX * 3];
 string doublehex = "000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F505152535455565758595A5B5C5D5E5F606162636465666768696A6B6C6D6E6F707172737475767778797A7B7C7D7E7F808182838485868788898A8B8C8D8E8F909192939495969798999A9B9C9D9E9FA0A1A2A3A4A5A6A7A8A9AAABACADAEAFB0B1B2B3B4B5B6B7B8B9BABBBCBDBEBFC0C1C2C3C4C5C6C7C8C9CACBCCCDCECFD0D1D2D3D4D5D6D7D8D9DADBDCDDDEDFE0E1E2E3E4E5E6E7E8E9EAEBECEDEEEFF0F1F2F3F4F5F6F7F8F9FAFBFCFDFEFFFF";
 // FF is contained twice, to map 256 to FF too
 // removes the need to bound()
 string doublehex = "000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F505152535455565758595A5B5C5D5E5F606162636465666768696A6B6C6D6E6F707172737475767778797A7B7C7D7E7F808182838485868788898A8B8C8D8E8F909192939495969798999A9B9C9D9E9FA0A1A2A3A4A5A6A7A8A9AAABACADAEAFB0B1B2B3B4B5B6B7B8B9BABBBCBDBEBFC0C1C2C3C4C5C6C7C8C9CACBCCCDCECFD0D1D2D3D4D5D6D7D8D9DADBDCDDDEDFE0E1E2E3E4E5E6E7E8E9EAEBECEDEEEFF0F1F2F3F4F5F6F7F8F9FAFBFCFDFEFFFF";
 // FF is contained twice, to map 256 to FF too
 // removes the need to bound()
+
+float RadarMap_Make(float argc);
+
+
 #endif
 #endif
index d4489106dac8d8bd71c151efc841ed9679cc9d9b..910d3e68e4e77fb34c2bd4e54836331044750024 100644 (file)
@@ -1,25 +1,40 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../warpzonelib/mathlib.qh"
-    #include "../../common/constants.qh"
-    #include "../../common/teams.qh"
-    #include "../../common/util.qh"
-    #include "../../common/command/shared_defs.qh"
-    #include "../../common/monsters/sv_monsters.qh"
-    #include "../autocvars.qh"
-    #include "../defs.qh"
-    #include "../../common/notifications.qh"
-    #include "../mutators/mutators_include.qh"
-    #include "../../common/mapinfo.qh"
-    #include "common.qh"
-    #include "cmd.qh"
-    #include "sv_cmd.qh"
-    #include "../anticheat.qh"
-    #include "../playerdemo.qh"
-#endif
+#include "sv_cmd.qh"
+#include "../_.qh"
+
+#include "banning.qh"
+#include "cmd.qh"
+#include "common.qh"
+#include "getreplies.qh"
+#include "radarmap.qh"
+
+#include "../anticheat.qh"
+#include "../campaign.qh"
+#include "../cl_client.qh"
+#include "../cl_player.qh"
+#include "../g_world.qh"
+#include "../ipban.qh"
+#include "../playerdemo.qh"
+#include "../teamplay.qh"
+
+#include "../bot/bot.qh"
+#include "../bot/navigation.qh"
+#include "../bot/scripting.qh"
+
+#include "../mutators/mutators_include.qh"
+
+#include "../../common/constants.qh"
+#include "../../common/mapinfo.qh"
+#include "../../common/notifications.qh"
+#include "../../common/teams.qh"
+#include "../../common/util.qh"
+
+#include "../../common/command/shared_defs.qh"
+
+#include "../../common/monsters/sv_monsters.qh"
+
+#include "../../warpzonelib/mathlib.qh"
+
+void PutObserverInServer (void);
 
 // =====================================================
 //  Server side game commands code, reworked by Samual
 
 // =====================================================
 //  Server side game commands code, reworked by Samual
index 61fd2f3a2d44d423b8a2a1792aec5f635a7ae420..4e2d4732d234fb4f2a41938bad53a223ff0b567a 100644 (file)
@@ -1,24 +1,23 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../../dpdefs/progsdefs.qh"
-    #include "../../dpdefs/dpextensions.qh"
-    #include "../../common/constants.qh"
-    #include "../../common/util.qh"
-    #include "../../common/command/shared_defs.qh"
-    #include "../autocvars.qh"
-    #include "../constants.qh"
-    #include "../defs.qh"
-    #include "../../common/notifications.qh"
-    #include "../mutators/mutators_include.qh"
-    #include "../../common/mapinfo.qh"
-    #include "common.qh"
-    #include "vote.qh"
-    #include "../../common/playerstats.qh"
-    #include "../scores.qh"
-    #include "../race.qh"
-    #include "../round_handler.qh"
-#endif
+#include "vote.qh"
+#include "../_.qh"
+
+#include "common.qh"
+
+#include "../g_damage.qh"
+#include "../g_world.qh"
+#include "../race.qh"
+#include "../round_handler.qh"
+#include "../scores.qh"
+
+#include "../mutators/mutators_include.qh"
+
+#include "../../common/constants.qh"
+#include "../../common/mapinfo.qh"
+#include "../../common/notifications.qh"
+#include "../../common/playerstats.qh"
+#include "../../common/util.qh"
+
+#include "../../common/command/shared_defs.qh"
 
 // =============================================
 //  Server side voting code, reworked by Samual
 
 // =============================================
 //  Server side voting code, reworked by Samual
index ff33f5668cf635f2f00acf8929d338df7e6d05c7..3c2845451d49653dacded2e1fbb712b808ba7141 100644 (file)
@@ -52,4 +52,5 @@ float restart_mapalreadyrestarted; // bool, indicates whether reset_map() was al
 .float ready; // flag for if a player is ready
 void reset_map(float dorespawn);
 void ReadyCount();
 .float ready; // flag for if a player is ready
 void reset_map(float dorespawn);
 void ReadyCount();
+void ReadyRestart_force();
 #endif
 #endif
diff --git a/qcsrc/server/csqceffects.qh b/qcsrc/server/csqceffects.qh
new file mode 100644 (file)
index 0000000..9fd0c38
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef CSQCEFFECTS_H
+#define CSQCEFFECTS_H
+void te_csqc_lightningarc(vector from,vector to);
+#endif
index 98ec277683c5477912cc1415f234c284a80754b5..f65e583719b0d7944fd3dd5201aac58830097ce9 100644 (file)
@@ -1,13 +1,7 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/constants.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "mutators/mutators_include.qh"
-#endif
+#include "_.qh"
+
+#include "defs.qh"
+#include "mutators/mutators_include.qh"
 
 /**
  * The point of these entities is to avoid the problems
 
 /**
  * The point of these entities is to avoid the problems
index be6104f1fa6d2c653cc6acb25bc3f818cab46840..763975c10e9f53fad174e7102e18e36b4ac86cc5 100644 (file)
@@ -1,3 +1,11 @@
+#include "_.qh"
+
+#include "g_subs.qh"
+#include "waypointsprites.qh"
+#include "g_damage.qh"
+#include "bot/bot.qh"
+#include "../common/csqcmodel_settings.qh"
+#include "../csqcmodellib/sv_model.qh"
 #include "weapons/common.qh"
 
 .entity sprite;
 #include "weapons/common.qh"
 
 .entity sprite;
index 82374c41b9cad824379f68c2880b906f98249ebe..62649079ff85a5e857a646402eab3d5b2ba84909 100644 (file)
@@ -1,12 +1,6 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-#endif
+#include "_.qh"
+
+#include "../common/util.qh"
 
 float Casing_SendEntity(entity to, int sf)
 {
 
 float Casing_SendEntity(entity to, int sf)
 {
index 0adae54b2e0286f7cf4ea52dc1c33528dd3de4aa..beed2e1b3ea259883e7b49458f4954e13f8bb1a4 100644 (file)
@@ -1,31 +1,26 @@
 #include "g_damage.qh"
 #include "g_damage.qh"
-
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-    #include "../warpzonelib/common.qh"
-    #include "../common/constants.qh"
-    #include "../common/teams.qh"
-    #include "../common/util.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "weapons/accuracy.qh"
-    #include "weapons/csqcprojectile.qh"
-    #include "weapons/selection.qh"
-    #include "t_items.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "../common/deathtypes.qh"
-    #include "mutators/mutators_include.qh"
-    #include "tturrets/include/turrets_early.qh"
-    #include "vehicles/vehicles_def.qh"
-    #include "../csqcmodellib/sv_model.qh"
-    #include "../common/playerstats.qh"
-    #include "g_hook.qh"
-    #include "scores.qh"
-    #include "spawnpoints.qh"
-#endif
+#include "_.qh"
+
+#include "g_hook.qh"
+#include "mutators/mutators_include.qh"
+#include "scores.qh"
+#include "waypointsprites.qh"
+#include "spawnpoints.qh"
+#include "tturrets/include/turrets_early.qh"
+#include "t_items.qh"
+#include "vehicles/vehicles_def.qh"
+#include "weapons/accuracy.qh"
+#include "weapons/csqcprojectile.qh"
+#include "weapons/selection.qh"
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/notifications.qh"
+#include "../common/playerstats.qh"
+#include "../common/teams.qh"
+#include "../common/util.qh"
+#include "../common/weapons/weapons.qh"
+#include "../csqcmodellib/sv_model.qh"
+#include "../warpzonelib/common.qh"
 
 float Damage_DamageInfo_SendEntity(entity to, int sf)
 {
 
 float Damage_DamageInfo_SendEntity(entity to, int sf)
 {
index 6a6c89b76897ef2d211fe5efd3cabefa34940c6c..1c6c3a7d8630d42beb083a0cbd691fa9a049c819 100644 (file)
@@ -1,21 +1,20 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/common.qh"
-    #include "../warpzonelib/server.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "vehicles/vehicles_def.qh"
-    #include "command/common.qh"
-    #include "g_hook.qh"
-    #include "round_handler.qh"
-#endif
+#include "g_hook.qh"
+#include "_.qh"
+
+#include "weapons/common.qh"
+#include "weapons/weaponsystem.qh"
+#include "weapons/selection.qh"
+#include "weapons/tracing.qh"
+#include "cl_player.qh"
+#include "t_teleporters.qh"
+#include "command/common.qh"
+#include "round_handler.qh"
+#include "vehicles/vehicles_def.qh"
+#include "../common/constants.qh"
+#include "../common/util.qh"
+#include "../common/weapons/weapons.qh"
+#include "../warpzonelib/common.qh"
+#include "../warpzonelib/server.qh"
 
 /*============================================
 
 
 /*============================================
 
index da53fbe64b2837689491d9b522780ac5999b9a27..bdcef35e7abd691fce0178bb02acfc57bde2a576 100644 (file)
@@ -1,3 +1,7 @@
+#include "_.qh"
+
+void train_next();
+
 const float LOOP = 1;
 
 const float DNOSHADOW = 2;
 const float LOOP = 1;
 
 const float DNOSHADOW = 2;
index 0214b9ed36b802156688eb1f98582e2b9c82b0af..afc32926b04584e686ff9c10b7c9a5feea82a267 100644 (file)
@@ -1,14 +1,10 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/constants.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../csqcmodellib/sv_model.qh"
-#endif
+#include "_.qh"
+
+#include "g_subs.qh"
+#include "g_triggers.qh"
+
+#include "../common/constants.qh"
+#include "../csqcmodellib/sv_model.qh"
 
 .float modelscale;
 
 
 .float modelscale;
 
index 74a8cf7f96126135f1ec45074a86d9d0036e3201..bcb3d61d25fd82f512baa277770a5ce7bf5e6c2f 100644 (file)
@@ -1,4 +1,9 @@
 #include "g_subs.qh"
 #include "g_subs.qh"
+#include "_.qh"
+
+#include "antilag.qh"
+#include "command/common.qh"
+#include "../warpzonelib/common.qh"
 
 void SUB_NullThink(void) { }
 
 
 void SUB_NullThink(void) { }
 
index 408eaf2e7e315312b406570a4347c75570fde49a..51ee3451e354d6c5cd6188767eb25aceb3a37109 100644 (file)
@@ -1,4 +1,10 @@
 #include "g_triggers.qh"
 #include "g_triggers.qh"
+#include "_.qh"
+
+#include "weapons/csqcprojectile.qh"
+#include "../common/deathtypes.qh"
+#include "../warpzonelib/util_server.qh"
+#include "g_subs.qh"
 #include "t_jumppads.qh"
 
 void SUB_DontUseTargets()
 #include "t_jumppads.qh"
 
 void SUB_DontUseTargets()
index 4ef4f45ff23e1b1453ab33ec3a3d775c393385b9..b103933ca867f485c50e138382f0805049af580d 100644 (file)
@@ -1,4 +1,5 @@
 #include "g_violence.qh"
 #include "g_violence.qh"
+#include "_.qh"
 
 float Violence_GibSplash_SendEntity(entity to, int sf)
 {
 
 float Violence_GibSplash_SendEntity(entity to, int sf)
 {
index a79f3fa91db6f74aea3273f434e59a75e73cb30e..25f86a63d942169770945128c92e020900658317 100644 (file)
@@ -1,39 +1,38 @@
 #include "g_world.qh"
 #include "g_world.qh"
-
+#include "_.qh"
+
+#include "anticheat.qh"
+#include "antilag.qh"
+#include "bot/bot.qh"
+#include "campaign.qh"
+#include "cheats.qh"
+#include "cl_client.qh"
+#include "command/common.qh"
+#include "command/getreplies.qh"
+#include "command/sv_cmd.qh"
+#include "command/vote.qh"
+#include "g_hook.qh"
+#include "ipban.qh"
+#include "mapvoting.qh"
+#include "mutators/mutators_include.qh"
+#include "race.qh"
+#include "scores.qh"
+#include "secret.qh"
+#include "teamplay.qh"
+#include "waypointsprites.qh"
+#include "weapons/weaponstats.qh"
 #include "../common/buffs.qh"
 #include "../common/buffs.qh"
-
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-    #include "../common/constants.qh"
-    #include "../common/stats.qh"
-    #include "../common/teams.qh"
-    #include "../common/util.qh"
-    #include "../common/monsters/sv_monsters.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "weapons/weaponstats.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "mutators/mutators_include.qh"
-    #include "campaign.qh"
-    #include "../common/mapinfo.qh"
-    #include "command/common.qh"
-    #include "command/vote.qh"
-    #include "command/getreplies.qh"
-    #include "command/sv_cmd.qh"
-    #include "anticheat.qh"
-    #include "cheats.qh"
-    #include "../common/playerstats.qh"
-    #include "g_hook.qh"
-    #include "scores.qh"
-    #include "mapvoting.qh"
-    #include "ipban.qh"
-    #include "race.qh"
-    #include "antilag.qh"
-    #include "secret.qh"
-#endif
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/mapinfo.qh"
+#include "../common/monsters/monsters.qh"
+#include "../common/monsters/sv_monsters.qh"
+#include "../common/notifications.qh"
+#include "../common/playerstats.qh"
+#include "../common/stats.qh"
+#include "../common/teams.qh"
+#include "../common/util.qh"
+#include "../common/weapons/weapons.qh"
 
 const float LATENCY_THINKRATE = 10;
 .float latency_sum;
 
 const float LATENCY_THINKRATE = 10;
 .float latency_sum;
@@ -93,9 +92,7 @@ string redirection_target;
 float world_initialized;
 
 string GetGametype();
 float world_initialized;
 
 string GetGametype();
-void GotoNextMap(float reinit);
 void ShuffleMaplist();
 void ShuffleMaplist();
-float(float reinit) DoNextMapOverride;
 
 void SetDefaultAlpha()
 {
 
 void SetDefaultAlpha()
 {
@@ -2036,7 +2033,6 @@ CheckRules_World
 Exit deathmatch games upon conditions
 ============
 */
 Exit deathmatch games upon conditions
 ============
 */
-void ReadyRestart();
 void CheckRules_World()
 {
        float timelimit;
 void CheckRules_World()
 {
        float timelimit;
index 3a5e5d5ac76b4d805a6ca9bde51d0cb219436d46..920ef71e184c1cc71d5962d57cd9c639f140d8f4 100644 (file)
@@ -13,5 +13,16 @@ const float WINNING_STARTSUDDENDEATHOVERTIME = 3; // no winner, enter suddendeat
 
 void CheckRules_Player();
 void IntermissionThink();
 
 void CheckRules_Player();
 void IntermissionThink();
+void GotoNextMap(float reinit);
+void ReadyRestart();
+
+void DumpStats(float final);
+float Map_IsRecent(string m);
+string GetNextMap();
+void ShuffleMaplist();
+void Map_Goto_SetStr(string nextmapname);
+void Map_Goto(float reinit);
+float DoNextMapOverride(float reinit);
+void CheckRules_World();
 
 #endif
 
 #endif
index 9591ee8baa9d9b7620d5b5fbe32f430a8e0a22cb..4499e0410e277931794a33aa629fa5772cf9d5ce 100644 (file)
@@ -1,15 +1,13 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "autocvars.qh"
-    #include "defs.qh"
-    #include "command/banning.qh"
-    #include "ipban.qh"
-#endif
+#include "ipban.qh"
+#include "_.qh"
+
+#include "autocvars.qh"
+#include "command/banning.qh"
+#include "defs.qh"
+#include "../common/constants.qh"
+#include "../common/util.qh"
+#include "../dpdefs/dpextensions.qh"
+#include "../dpdefs/progsdefs.qh"
 
 /*
  * Protocol of online ban list:
 
 /*
  * Protocol of online ban list:
index b2bbd86ccc44d8d697df821528b5cb2b24c5642d..5fa7834d1ce23e2751a7f689dd5e5e5c00726bd7 100644 (file)
@@ -1,15 +1,10 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/util_server.qh"
-    #include "../common/util.qh"
-    #include "../common/monsters/monsters.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "item_key.qh"
-#endif
+#include "item_key.qh"
+#include "_.qh"
+
+#include "../common/monsters/monsters.qh"
+#include "../common/notifications.qh"
+#include "../common/util.qh"
+#include "../warpzonelib/util_server.qh"
 
 /*
 TODO:
 
 /*
 TODO:
index 178dfe7ba5986769ed8e567b35c86401a0c0e206..334571f08dded5dfba2a95f827793f230657523d 100644 (file)
@@ -1,19 +1,13 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/mapinfo.qh"
-    #include "command/getreplies.qh"
-    #include "command/cmd.qh"
-    #include "../common/playerstats.qh"
-    #include "mapvoting.qh"
-#endif
+#include "mapvoting.qh"
+#include "_.qh"
+
+#include "g_world.qh"
+#include "command/cmd.qh"
+#include "command/getreplies.qh"
+#include "../common/constants.qh"
+#include "../common/mapinfo.qh"
+#include "../common/playerstats.qh"
+#include "../common/util.qh"
 
 float GameTypeVote_AvailabilityStatus(string gtname)
 {
 
 float GameTypeVote_AvailabilityStatus(string gtname)
 {
index d2eff1cf08ec0422fef2292e25326ee96244ac65..18194b7b6b08362a942bef1b0514b9a211ff805f 100644 (file)
@@ -1,10 +1,13 @@
 #ifndef MAPVOTING_H
 #define MAPVOTING_H
 
 #ifndef MAPVOTING_H
 #define MAPVOTING_H
 
+#include "../common/constants.qh"
+
 // definitions for functions used outside mapvoting.qc
 void MapVote_Start();
 void MapVote_Spawn();
 void MapVote_Think();
 // definitions for functions used outside mapvoting.qc
 void MapVote_Start();
 void MapVote_Spawn();
 void MapVote_Think();
+void MapVote_SendPicture(float id);
 float GameTypeVote_Start();
 float GameTypeVote_Finished(float pos);
 string GameTypeVote_MapInfo_FixName(string m);
 float GameTypeVote_Start();
 float GameTypeVote_Finished(float pos);
 string GameTypeVote_MapInfo_FixName(string m);
index 3d353c75cb1ab1c08eef354e4c1c3bb038b4422b..4a0139080c98ceb90a88ec27d81ee8254f15140c 100644 (file)
@@ -1,34 +1,29 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "miscfunctions.qh"
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/playerstats.qh"
-    #include "../warpzonelib/anglestransform.qh"
-    #include "../warpzonelib/server.qh"
-    #include "../common/constants.qh"
-    #include "../common/teams.qh"
-    #include "../common/util.qh"
-    #include "../common/urllib.qh"
-    #include "../common/command/generic.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "weapons/accuracy.qh"
-    #include "weapons/csqcprojectile.qh"
-    #include "weapons/selection.qh"
-    #include "t_items.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "../common/deathtypes.qh"
-    #include "mutators/mutators_include.qh"
-    #include "tturrets/include/turrets_early.qh"
-    #include "../common/mapinfo.qh"
-    #include "command/common.qh"
-    #include "../csqcmodellib/sv_model.qh"
-    #include "ipban.qh"
-#endif
+#include "miscfunctions.qh"
+#include "_.qh"
+
+#include "antilag.qh"
+#include "command/common.qh"
+#include "constants.qh"
+#include "ipban.qh"
+#include "mutators/mutators_include.qh"
+#include "tturrets/include/turrets_early.qh"
+#include "t_items.qh"
+#include "weapons/accuracy.qh"
+#include "weapons/csqcprojectile.qh"
+#include "weapons/selection.qh"
+#include "../common/command/generic.qh"
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/mapinfo.qh"
+#include "../common/notifications.qh"
+#include "../common/playerstats.qh"
+#include "../common/teams.qh"
+#include "../common/urllib.qh"
+#include "../common/util.qh"
+#include "../common/weapons/weapons.qh"
+#include "../csqcmodellib/sv_model.qh"
+#include "../warpzonelib/anglestransform.qh"
+#include "../warpzonelib/server.qh"
 
 void crosshair_trace(entity pl)
 {
 
 void crosshair_trace(entity pl)
 {
@@ -1303,7 +1298,6 @@ void Net_LinkEntity(entity e, float docull, float dt, bool(entity, int) sendfunc
 }
 
 
 }
 
 
-entity eliminatedPlayers;
 .float(entity) isEliminated;
 float EliminatedPlayers_SendEntity(entity to, float sendflags)
 {
 .float(entity) isEliminated;
 float EliminatedPlayers_SendEntity(entity to, float sendflags)
 {
index f19f53fd0b3010d021308c2a29235f195097d1d1..b8d1fc53335072011ee7698bda67187477ef30c7 100644 (file)
@@ -32,6 +32,42 @@ float cvar_normal(string n)
 .float uncustomizeentityforclient_set;
 .float nottargeted;
 
 .float uncustomizeentityforclient_set;
 .float nottargeted;
 
+entity eliminatedPlayers;
+void EliminatedPlayers_Init(float(entity) isEliminated_func);
+
+string admin_name(void);
+
+void write_recordmarker(entity pl, float tstart, float dt);
+
+void play2all(string samp);
+
+void DistributeEvenly_Init(float amount, float totalweight);
+float DistributeEvenly_Get(float weight);
+
+void modeleffect_spawn(string m, float s, float f, vector o, vector v, vector ang, vector angv, float s0, float s2, float a, float t1, float t2);
+
+void shockwave_spawn(string m, vector org, float sz, float t1, float t2);
+
+vector randompos(vector m1, vector m2);
+
+void play2team(float t, string filename);
+
+void GetCvars_handleFloat(string thisname, float f, .float field, string name);
+
+float spamsound(entity e, float chan, string samp, float vol, float _atten);
+
+void GetCvars_handleString(string thisname, float f, .string field, string name);
+
+void precache_all_playermodels(string pattern);
+
+void soundat(entity e, vector o, float chan, string samp, float vol, float _atten);
+
+void defer(float fdelay, void() func);
+
+void UncustomizeEntitiesRun();
+void InitializeEntitiesRun();
+
+void stopsoundto(float _dest, entity e, float chan);
 
 float DistributeEvenly_amount;
 float DistributeEvenly_totalweight;
 
 float DistributeEvenly_amount;
 float DistributeEvenly_totalweight;
@@ -68,6 +104,8 @@ float isPushable(entity e);
 
 float LostMovetypeFollow(entity ent);
 
 
 float LostMovetypeFollow(entity ent);
 
+string uid2name(string myuid);
+
 float MoveToRandomMapLocation(entity e, float goodcontents, float badcontents, float badsurfaceflags, float attempts, float maxaboveground, float minviewdistance);
 
 string NearestLocation(vector p);
 float MoveToRandomMapLocation(entity e, float goodcontents, float badcontents, float badsurfaceflags, float attempts, float maxaboveground, float minviewdistance);
 
 string NearestLocation(vector p);
index 71bcd9e58700f3f78b824d317ccab2902f5593c4..81f759c8bebc53f5f38e1d18b99dd0222e7f0124 100644 (file)
@@ -1,3 +1,6 @@
+#include "base.qh"
+#include "../_.qh"
+
 .float() cbc_func;
 .entity cbc_next;
 .float cbc_order;
 .float() cbc_func;
 .entity cbc_next;
 .float cbc_order;
diff --git a/qcsrc/server/mutators/gamemode.qh b/qcsrc/server/mutators/gamemode.qh
new file mode 100644 (file)
index 0000000..38e9ad8
--- /dev/null
@@ -0,0 +1,49 @@
+#ifndef GAMEMODE_H
+#define GAMEMODE_H
+
+#include "mutator_nades.qh"
+
+#include "../cl_client.qh"
+#include "../cl_player.qh"
+#include "../cl_impulse.qh"
+#include "../cheats.qh"
+#include "../g_damage.qh"
+#include "../g_subs.qh"
+#include "../t_teleporters.qh"
+#include "../round_handler.qh"
+#include "../scores.qh"
+#include "../scores_rules.qh"
+#include "../waypointsprites.qh"
+
+#include "../bot/bot.qh"
+#include "../bot/navigation.qh"
+#include "../bot/waypoints.qh"
+#include "../bot/havocbot/roles.qh"
+#include "../bot/havocbot/role_keyhunt.qh"
+
+#include "../bot/havocbot/havocbot.qh"
+
+#include "../command/vote.qh"
+
+#include "../../common/monsters/monsters.qh"
+
+#include "../command/common.qh"
+
+#include "../weapons/tracing.qh"
+#include "../weapons/weaponsystem.qh"
+
+#include "../../common/deathtypes.qh"
+#include "../../common/notifications.qh"
+#include "../../common/stats.qh"
+#include "../../common/teams.qh"
+
+#include "../../warpzonelib/mathlib.qh"
+#include "../../warpzonelib/server.qh"
+#include "../../warpzonelib/util_server.qh"
+
+.float lastground;
+float total_players;
+float redalive, bluealive, yellowalive, pinkalive;
+.float redalive_stat, bluealive_stat, yellowalive_stat, pinkalive_stat;
+
+#endif
index 49deac0e8f350c1f73cfea58694a21ac7927af5b..d14d9da8c7c5fe2bd42854510b8c1fb8c00a3f86 100644 (file)
@@ -1,3 +1,10 @@
+#include "gamemode_assault.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+.entity sprite;
+
 // random functions
 void assault_objective_use()
 {
 // random functions
 void assault_objective_use()
 {
index a0f238358455a271a80a45d996ecf9c07fe16f36..ab198e30e81d872cb87fa7bd9c96f8a8ccb7623f 100644 (file)
@@ -1,6 +1,8 @@
-float total_players;
-float redalive, bluealive, yellowalive, pinkalive;
-.float redalive_stat, bluealive_stat, yellowalive_stat, pinkalive_stat;
+#include "gamemode_ca.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 float ca_teams;
 float allowed_to_spawn;
 
 float ca_teams;
 float allowed_to_spawn;
 
index 0cbcf714c906f956c979c47257a496634ebf894e..d40263fb72f41bd7b754d42a849aa288dc55f2ca 100644 (file)
@@ -1,3 +1,13 @@
+#include "gamemode_ctf.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../vehicles/vehicles_def.qh"
+
+#include "../../warpzonelib/common.qh"
+#include "../../warpzonelib/mathlib.qh"
+
 // ================================================================
 //  Official capture the flag game mode coding, reworked by Samual
 //  Last updated: September, 2012
 // ================================================================
 //  Official capture the flag game mode coding, reworked by Samual
 //  Last updated: September, 2012
index 0e5930db2cbe83c95b439e8f75461cdce64eda7f..302f6ce104b305054a8f3dd36830a5a3b8200025 100644 (file)
@@ -93,6 +93,8 @@ const float RETURN_DAMAGE = 3;
 const float RETURN_SPEEDRUN = 4;
 const float RETURN_NEEDKILL = 5;
 
 const float RETURN_SPEEDRUN = 4;
 const float RETURN_NEEDKILL = 5;
 
+void ctf_Handle_Throw(entity player, entity receiver, float droptype);
+
 // flag properties
 #define ctf_spawnorigin dropped_origin
 float ctf_stalemate; // indicates that a stalemate is active
 // flag properties
 #define ctf_spawnorigin dropped_origin
 float ctf_stalemate; // indicates that a stalemate is active
index 0886a9ce59921cf205bc71dba4a89bc9897b3846..aa5a936e7f3f3c74e48e564aaa0597afa5cd1cfd 100644 (file)
@@ -1,3 +1,10 @@
+#include "gamemode_cts.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../race.qh"
+
 // legacy bot roles
 .float race_checkpoint;
 void havocbot_role_cts()
 // legacy bot roles
 .float race_checkpoint;
 void havocbot_role_cts()
index dd6e8b2109be3b97ceab791a5874a8ec94edf880..d2df87cb85c02dcbe3b2a221f80fc35e4fae2a00 100644 (file)
@@ -1,3 +1,8 @@
+#include "gamemode_domination.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 void dom_EventLog(string mode, float team_before, entity actor) // use an alias for easy changing and quick editing later
 {
        if(autocvar_sv_eventlog)
 void dom_EventLog(string mode, float team_before, entity actor) // use an alias for easy changing and quick editing later
 {
        if(autocvar_sv_eventlog)
index d6285cdafd112509b99e8c9ffcacd6b0430e3abe..779e15d575884b464171660ecadb54508c4c71d4 100644 (file)
@@ -1,8 +1,7 @@
-.float freezetag_frozen_time;
-.float freezetag_frozen_timeout;
-const float ICE_MAX_ALPHA = 1;
-const float ICE_MIN_ALPHA = 0.1;
-float freezetag_teams;
+#include "gamemode_freezetag.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
 
 const float SP_FREEZETAG_REVIVALS = 4;
 void freezetag_ScoreRules(float teams)
 
 const float SP_FREEZETAG_REVIVALS = 4;
 void freezetag_ScoreRules(float teams)
@@ -425,7 +424,6 @@ MUTATOR_HOOKFUNCTION(freezetag_GiveFragsForKill)
        return 1;
 }
 
        return 1;
 }
 
-.float reviving; // temp var
 MUTATOR_HOOKFUNCTION(freezetag_PlayerPreThink)
 {
        float n;
 MUTATOR_HOOKFUNCTION(freezetag_PlayerPreThink)
 {
        float n;
diff --git a/qcsrc/server/mutators/gamemode_freezetag.qh b/qcsrc/server/mutators/gamemode_freezetag.qh
new file mode 100644 (file)
index 0000000..19489fc
--- /dev/null
@@ -0,0 +1,11 @@
+#ifndef GAMEMODE_FREEZETAG_H
+#define GAMEMODE_FREEZETAG_H
+.float freezetag_frozen_time;
+.float freezetag_frozen_timeout;
+const float ICE_MAX_ALPHA = 1;
+const float ICE_MIN_ALPHA = 0.1;
+float freezetag_teams;
+
+.float reviving; // temp var
+
+#endif
index fe0d0a7ecc4094048a9a7b878e2428a0ad258523..5720e55d85d68a710d29fc1774e597298a05dfe6 100644 (file)
@@ -1,3 +1,11 @@
+#include "gamemode_invasion.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../../common/monsters/spawn.qh"
+#include "../../common/monsters/sv_monsters.qh"
+
 void spawnfunc_invasion_spawnpoint()
 {
        if(!g_invasion) { remove(self); return; }
 void spawnfunc_invasion_spawnpoint()
 {
        if(!g_invasion) { remove(self); return; }
index 095857e14325ebf83550b5feee918024d9bb07e4..687839c0e839cad3a7260c3356fdec494852dd50 100644 (file)
@@ -1,3 +1,8 @@
+#include "gamemode_keepaway.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 // ===========================================================
 //  Keepaway game mode coding, written by Samual and Diabolik
 //  Last updated: September, 2012
 // ===========================================================
 //  Keepaway game mode coding, written by Samual and Diabolik
 //  Last updated: September, 2012
index fd9ed4f2f0e98b9b2c5a29ce9b0736dd99df4187..250f2fbc9f45979a0e48c05c454e0ec6f4a5f000 100644 (file)
@@ -11,4 +11,7 @@ const float SP_KEEPAWAY_BCTIME = 6;
 
 void() havocbot_role_ka_carrier;
 void() havocbot_role_ka_collector;
 
 void() havocbot_role_ka_carrier;
 void() havocbot_role_ka_collector;
+
+void ka_DropEvent(entity plyr);
+
 #endif
 #endif
index d0103d80ef17248ca2e365e92d2f91fdfb6b1b7f..780aba8d8c93ef901c7aaba14096d29548d7b654 100644 (file)
@@ -1,4 +1,8 @@
-#define FOR_EACH_KH_KEY(v) for(v = kh_worldkeylist; v; v = v.kh_worldkeynext )
+#include "gamemode_keyhunt.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 
 // #define KH_PLAYER_USE_ATTACHMENT
 // #define KH_PLAYER_USE_CARRIEDMODEL
 
 // #define KH_PLAYER_USE_ATTACHMENT
 // #define KH_PLAYER_USE_CARRIEDMODEL
index 6b27431c2207cc81f39319b3d6c580477451d2cc..4d1645d02c0201ecebe82485e1f771f025e69b82 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef GAMEMODE_KEYHUNT_H
 #define GAMEMODE_KEYHUNT_H
 
 #ifndef GAMEMODE_KEYHUNT_H
 #define GAMEMODE_KEYHUNT_H
 
+#define FOR_EACH_KH_KEY(v) for(v = kh_worldkeylist; v; v = v.kh_worldkeynext )
+
 // ALL OF THESE should be removed in the future, as other code should not have to care
 
 // used by bots:
 // ALL OF THESE should be removed in the future, as other code should not have to care
 
 // used by bots:
@@ -11,4 +13,7 @@ float kh_Key_AllOwnedByWhichTeam();
 typedef void(void) kh_Think_t;
 void kh_StartRound();
 void kh_Controller_SetThink(float t, kh_Think_t func);
 typedef void(void) kh_Think_t;
 void kh_StartRound();
 void kh_Controller_SetThink(float t, kh_Think_t func);
+
+void kh_Key_DropAll(entity player, float suicide);
+
 #endif
 #endif
index 13b77305a25429c78dd95768701167057b7a699e..9f658df840e96d63768222d285df460e8e44e83f 100644 (file)
@@ -1,3 +1,11 @@
+#include "gamemode_lms.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../campaign.qh"
+#include "../command/cmd.qh"
+
 // main functions
 float LMS_NewPlayerLives()
 {
 // main functions
 float LMS_NewPlayerLives()
 {
index afdb769cf6b0c4025bc6e31f7f175f1557520982..3e5c19523c342caf2844bea7a7dbdd72933b3d65 100644 (file)
@@ -1,3 +1,10 @@
+#include "gamemode_nexball.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../t_jumppads.qh"
+
 float autocvar_g_nexball_safepass_turnrate;
 float autocvar_g_nexball_safepass_maxdist;
 float autocvar_g_nexball_safepass_holdtime;
 float autocvar_g_nexball_safepass_turnrate;
 float autocvar_g_nexball_safepass_maxdist;
 float autocvar_g_nexball_safepass_holdtime;
index 7d02e6ff91da634f5197e81521e9e6ba37d27716..06aaeddd4f444c72b58323dfcb8826bf5a7661ee 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 float autocvar_g_onslaught_spawn_at_controlpoints;
 float autocvar_g_onslaught_spawn_at_generator;
 float autocvar_g_onslaught_cp_proxydecap;
 float autocvar_g_onslaught_spawn_at_controlpoints;
 float autocvar_g_onslaught_spawn_at_generator;
 float autocvar_g_onslaught_cp_proxydecap;
index 7ba8328469765b40513ba9160aceb139b2bf3873..26a06e3fc757c8be7c0e93432a69162e606635ac 100644 (file)
@@ -1,3 +1,10 @@
+#include "gamemode_race.qh"
+#include "../_.qh"
+
+#include "gamemode.qh"
+
+#include "../race.qh"
+
 // legacy bot roles
 .float race_checkpoint;
 void havocbot_role_race()
 // legacy bot roles
 .float race_checkpoint;
 void havocbot_role_race()
index de172873e29255af8f14c0c8ae972758519f5c60..67cbeba68ea2453e859af848be585f8536d28963 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "gamemode.qh"
+
 /*QUAKED spawnfunc_tdm_team (0 .5 .8) (-16 -16 -24) (16 16 32)
 Team declaration for TDM gameplay, this allows you to decide what team names and control point models are used in your map.
 Note: If you use spawnfunc_tdm_team entities you must define at least 2!  However, unlike domination, you don't need to make a blank one too.
 /*QUAKED spawnfunc_tdm_team (0 .5 .8) (-16 -16 -24) (16 16 32)
 Team declaration for TDM gameplay, this allows you to decide what team names and control point models are used in your map.
 Note: If you use spawnfunc_tdm_team entities you must define at least 2!  However, unlike domination, you don't need to make a blank one too.
diff --git a/qcsrc/server/mutators/mutator.qh b/qcsrc/server/mutators/mutator.qh
new file mode 100644 (file)
index 0000000..6cded53
--- /dev/null
@@ -0,0 +1,47 @@
+#ifndef MUTATOR_H
+#define MUTATOR_H
+
+#include "base.qh"
+#include "mutator_nades.qh"
+
+#include "../cl_client.qh"
+#include "../cl_player.qh"
+#include "../cl_impulse.qh"
+#include "../cheats.qh"
+#include "../g_damage.qh"
+#include "../g_subs.qh"
+#include "../t_teleporters.qh"
+#include "../round_handler.qh"
+#include "../scores.qh"
+#include "../scores_rules.qh"
+#include "../waypointsprites.qh"
+
+#include "../bot/bot.qh"
+#include "../bot/navigation.qh"
+#include "../bot/waypoints.qh"
+
+#include "../bot/havocbot/havocbot.qh"
+#include "../bot/havocbot/roles.qh"
+#include "../bot/havocbot/role_keyhunt.qh"
+
+#include "../command/vote.qh"
+#include "../command/common.qh"
+
+#include "../weapons/common.qh"
+#include "../weapons/tracing.qh"
+#include "../weapons/throwing.qh"
+#include "../weapons/weaponsystem.qh"
+
+#include "../../common/deathtypes.qh"
+#include "../../common/notifications.qh"
+#include "../../common/stats.qh"
+#include "../../common/teams.qh"
+
+#include "../../common/monsters/monsters.qh"
+
+#include "../../warpzonelib/anglestransform.qh"
+#include "../../warpzonelib/mathlib.qh"
+#include "../../warpzonelib/server.qh"
+#include "../../warpzonelib/util_server.qh"
+
+#endif
index 08e14199ee3f4d460044f02f056cc2750b2692a0..910c7143a1342d01d78f57361ba7dcf0782ffa49 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 .float bloodloss_timer;
 
 MUTATOR_HOOKFUNCTION(bloodloss_PlayerThink)
 .float bloodloss_timer;
 
 MUTATOR_HOOKFUNCTION(bloodloss_PlayerThink)
index b2f800a27e06c1228d541cbabc47ef221c04ae9d..fc7bd42c7be5962864d0137de2c4f0ff9a52c954 100644 (file)
@@ -1,3 +1,12 @@
+#include "mutator_buffs.qh"
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "../../common/buffs.qh"
+
+.float lifetime;
+
 float buffs_BuffModel_Customize()
 {
        entity player, myowner;
 float buffs_BuffModel_Customize()
 {
        entity player, myowner;
index 21dd71f98b5dfc74302c10c01510b37073ee2fb3..19936b359a40e8130d3d2fce814b64bf92efa37c 100644 (file)
@@ -1,3 +1,9 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "../campaign.qh"
+
 .float campcheck_nextcheck;
 .float campcheck_traveled_distance;
 
 .float campcheck_nextcheck;
 .float campcheck_traveled_distance;
 
index 58d24a4d820c526376026c84bfa1c774e1506545..a293b9f96a05c56bf4279ecb5e3946c83a7696bf 100644 (file)
@@ -1,3 +1,9 @@
+#include "mutator_dodging.qh"
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "../../common/animdecide.qh"
 
 .float cvar_cl_dodging_timeout;
 
 
 .float cvar_cl_dodging_timeout;
 
index b3502b0f783573c6467ec9752dc13d4d13326f0b..a7564a0dff061d1a5403070296472018b3469da5 100644 (file)
@@ -1,3 +1,10 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "../cl_client.qh"
+#include "../../common/buffs.qh"
+
 void spawnfunc_item_minst_cells (void)
 {
        if (!g_instagib) { remove(self); return; }
 void spawnfunc_item_minst_cells (void)
 {
        if (!g_instagib) { remove(self); return; }
index d1ab520001d4580b25bbd1d07470401a8b843fd0..7c20c103725cf74ec125a452a11ecda587bac9e7 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 MUTATOR_HOOKFUNCTION(invincibleprojectiles_EditProjectile)
 {
        if(other.health)
 MUTATOR_HOOKFUNCTION(invincibleprojectiles_EditProjectile)
 {
        if(other.health)
index b4f9c37716c39c70426d05b5039a4735f84c37e8..3ffc0ffddc22ebe9fee18d9722716a292f81529d 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 MUTATOR_HOOKFUNCTION(melee_SetStartItems)
 {
        start_ammo_shells = warmup_start_ammo_shells = 0;
 MUTATOR_HOOKFUNCTION(melee_SetStartItems)
 {
        start_ammo_shells = warmup_start_ammo_shells = 0;
index d582c05ce7d39b3150eed52452e49cb99f1e1d78..fdffd6ed700c21805f462e20d2560d026cebbb35 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 .float midair_shieldtime;
 
 MUTATOR_HOOKFUNCTION(midair_PlayerDamage)
 .float midair_shieldtime;
 
 MUTATOR_HOOKFUNCTION(midair_PlayerDamage)
index d36f3ecbe82e566a030968198c11564cbefb7a2c..584ece8f1987ce52ca25faf23e3f61c4ba4fdd22 100644 (file)
@@ -1,3 +1,9 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "../antilag.qh"
+
 .float multijump_count;
 .float multijump_ready;
 
 .float multijump_count;
 .float multijump_ready;
 
index 8f7857b166846d58df78307e02a7eea8f444dd60..ddcd81915f410d7a2ee1809a3b666e39bb484d96 100644 (file)
@@ -1,3 +1,16 @@
+#include "mutator_nades.qh"
+#include "../_.qh"
+
+#include "mutator.qh"
+
+#include "gamemode_keyhunt.qh"
+#include "gamemode_freezetag.qh"
+#include "../../common/nades.qh"
+#include "../../common/monsters/spawn.qh"
+#include "../../common/monsters/sv_monsters.qh"
+
+.float lifetime;
+
 .entity nade_spawnloc;
 
 void nade_timer_think()
 .entity nade_spawnloc;
 
 void nade_timer_think()
index 5aa94b1875d8d070ac6c76250874f586d31fdfcd..bca6595c141218658f422c814f1b13145ce02519 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 /*
 
 CORE    laser   vortex     lg      rl      cry     gl      elec    hagar   fireb   hook
 /*
 
 CORE    laser   vortex     lg      rl      cry     gl      elec    hagar   fireb   hook
index ec5574527de33f524b935a3d616761290d1f6236..eb7f8f75b6bc48338f4fbf5b29e6100cc4599ba6 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 float g_nix_with_blaster;
 // WEAPONTODO
 int nix_weapon;
 float g_nix_with_blaster;
 // WEAPONTODO
 int nix_weapon;
index b707fbee0cac7b78cb94ff84b6115430c4973b69..ccf499a3451d5147e7cdd579698812e22b8fdcc1 100644 (file)
@@ -1,3 +1,12 @@
+#include "mutator_overkill.qh"
+#include "../_.qh"
+
+#include "mutator.qh"
+
+void W_Blaster_Attack(float, float, float, float, float, float, float, float, float, float);
+void spawnfunc_weapon_hmg();
+void spawnfunc_weapon_rpc();
+
 void ok_DecreaseCharge(entity ent, int wep)
 {
        if(!ent.ok_use_ammocharge) return;
 void ok_DecreaseCharge(entity ent, int wep)
 {
        if(!ent.ok_use_ammocharge) return;
index 4963b3c8fe3cbee6a47b33e210e124eba3744ad7..1554ed7baca50538deede913300b9527560bc55f 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 .vector spawn_origin, spawn_angles;
 
 void physical_item_think()
 .vector spawn_origin, spawn_angles;
 
 void physical_item_think()
index 7cf405ef7679cc0331c5d89fb622d42cf1d97f5c..235eee59c1b13b5125d41f762d18a547469b0ac8 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 MUTATOR_HOOKFUNCTION(pinata_PlayerDies)
 {
        float j;
 MUTATOR_HOOKFUNCTION(pinata_PlayerDies)
 {
        float j;
index f70ee4ba32c9d01d312a81a81e67ebfc9c34f5e2..27fcbf99e2b6e68374dc476060d5b99de66542a3 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 // Random Gravity
 //
 // Mutator by Mario
 // Random Gravity
 //
 // Mutator by Mario
index 03a5bde619683445ac5929017ca51ade53936b71..db1bb78e32951bcebd9cbc97f7c97f4ed9c7a514 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 MUTATOR_HOOKFUNCTION(rocketflying_EditProjectile)
 {
        if(other.classname == "rocket" || other.classname == "mine")
 MUTATOR_HOOKFUNCTION(rocketflying_EditProjectile)
 {
        if(other.classname == "rocket" || other.classname == "mine")
index 8dc3bbc6c0ad049c50ed1702825221901a56b635..82c5a0e51c112c99e6fabfe6061f045f39990c4d 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 .entity msnt_lookat;
 
 .float msnt_timer;
 .entity msnt_lookat;
 
 .float msnt_timer;
index 1fd1022e72d2131d57edacd22c8ed8e2df2f6c6e..8c065af510c74b740f46b2d22d718a22023a60aa 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 #define _SSMAGIX "SUPERSPEC_OPTIONSFILE_V1"
 #define _ISLOCAL ((edict_num(1) == self) ? true : false)
 
 #define _SSMAGIX "SUPERSPEC_OPTIONSFILE_V1"
 #define _ISLOCAL ((edict_num(1) == self) ? true : false)
 
index fb58b3955cbbbcae1913b3628bce8e354a521dff..e3507c678d36a84e3fe653851fba1ff8efd8ec1a 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 .float touchexplode_time;
 
 void PlayerTouchExplode(entity p1, entity p2)
 .float touchexplode_time;
 
 void PlayerTouchExplode(entity p1, entity p2)
index aa45fc1acfb777fea7c1ea078f38767fded15f42..2b12f7a8b402a92aebadff9e9380101b59401dd4 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 MUTATOR_HOOKFUNCTION(vampire_PlayerDamage)
 {
        if(time >= frag_target.spawnshieldtime)
 MUTATOR_HOOKFUNCTION(vampire_PlayerDamage)
 {
        if(time >= frag_target.spawnshieldtime)
index f66b5019a603b06402290bd58adaf82d12d87563..8807f25d9196d9133ebb13d9e744b77b6d8b520c 100644 (file)
@@ -1,3 +1,7 @@
+#include "../_.qh"
+
+#include "mutator.qh"
+
 const float MAX_STORAGE_ATTACHMENTS = 16;
 float object_count;
 .float object_flood;
 const float MAX_STORAGE_ATTACHMENTS = 16;
 float object_count;
 .float object_flood;
index 2f66441f7a00111eaca7ab8b4795ca06c15a65f1..a24b431f9c115c8007a2379e04c2c9cafa959589 100644 (file)
@@ -1,54 +1,11 @@
-//#define PATHLIB_RDFIELDS
-#ifdef PATHLIB_RDFIELDS
-    #define path_next swampslug
-    #define path_prev lasertarget
-#else
-    .entity path_next;
-    .entity path_prev;
-#endif
+#include "pathlib.qh"
+#include "_.qh"
+
+#include "g_subs.qh"
 
 #define medium spawnshieldtime
 
 //#define DEBUGPATHING
 
 #define medium spawnshieldtime
 
 //#define DEBUGPATHING
-
-entity openlist;
-entity closedlist;
-entity scraplist;
-
-.float pathlib_node_g;
-.float pathlib_node_h;
-.float pathlib_node_f;
-
-float pathlib_open_cnt;
-float pathlib_closed_cnt;
-float pathlib_made_cnt;
-float pathlib_merge_cnt;
-float pathlib_recycle_cnt;
-float pathlib_searched_cnt;
-
-#ifdef DEBUGPATHING
-
-#endif
-
-float pathlib_bestopen_seached;
-float pathlib_bestcash_hits;
-float pathlib_bestcash_saved;
-
-float pathlib_gridsize;
-
-float pathlib_movecost;
-float pathlib_movecost_diag;
-float pathlib_movecost_waterfactor;
-
-float pathlib_edge_check_size;
-
-float pathlib_foundgoal;
-entity goal_node;
-
-entity best_open_node;
-.float is_path_node;
-
-
 #ifdef DEBUGPATHING
 float edge_show(vector point,float fsize);
 void mark_error(vector where,float lifetime);
 #ifdef DEBUGPATHING
 float edge_show(vector point,float fsize);
 void mark_error(vector where,float lifetime);
@@ -161,16 +118,6 @@ float floor_ok(vector point)
     return 0;
 }
 
     return 0;
 }
 
-#define inwater(point) (pointcontents(point) == CONTENT_WATER)
-/*
-float inwater(vector point)
-{
-    if(pointcontents(point) == CONTENT_WATER)
-        return 1;
-    return 0;
-}
-*/
-
 #define _pcheck(p) traceline(p+z_up,p-z_down,MOVE_WORLDONLY,self); if (!floor_ok(trace_endpos)) return 1
 float edge_check(vector point,float fsize)
 {
 #define _pcheck(p) traceline(p+z_up,p-z_down,MOVE_WORLDONLY,self); if (!floor_ok(trace_endpos)) return 1
 float edge_check(vector point,float fsize)
 {
@@ -259,7 +206,7 @@ vector pathlib_swimnode(vector start,vector end,float doedge)
     end.y = fsnap(end.y, pathlib_gridsize);
 
     if(pointcontents(end) == CONTENT_EMPTY)
     end.y = fsnap(end.y, pathlib_gridsize);
 
     if(pointcontents(end) == CONTENT_EMPTY)
-        return pathlib_wateroutnode( start, end);
+        return pathlib_wateroutnode( start, end, doedge);
 
     tracebox(start, walknode_boxmin,walknode_boxmax, end, MOVE_WORLDONLY, self);
     if(trace_fraction == 1)
 
     tracebox(start, walknode_boxmin,walknode_boxmax, end, MOVE_WORLDONLY, self);
     if(trace_fraction == 1)
@@ -519,7 +466,6 @@ float pathlib_h_diagonal3(vector a,vector b)
     return h;
 }
 
     return h;
 }
 
-//#define PATHLIB_USE_NODESCRAP
 const float PATHLIB_NODEEXPIRE = 0.05;
 float pathlib_scraplist_cnt;
 entity newnode()
 const float PATHLIB_NODEEXPIRE = 0.05;
 float pathlib_scraplist_cnt;
 entity newnode()
@@ -541,7 +487,6 @@ entity newnode()
 #endif
     ++pathlib_made_cnt;
     n = spawn();
 #endif
     ++pathlib_made_cnt;
     n = spawn();
-#ifdef PATHLIB_NODEEXPIRE
     n.think      = SUB_Remove;
     n.nextthink  = time + PATHLIB_NODEEXPIRE;
     return n;
     n.think      = SUB_Remove;
     n.nextthink  = time + PATHLIB_NODEEXPIRE;
     return n;
@@ -736,7 +681,7 @@ float pathlib_expandnode_star(entity node, vector start, vector goal)
 {
     vector point;
     vector where;
 {
     vector point;
     vector where;
-    float nodecnt;
+    float nodecnt = 0;
 
     where = node.origin;
 
 
     where = node.origin;
 
@@ -1044,6 +989,3 @@ entity pathlib_astar(vector from,vector to)
 
     return world;
 }
 
     return world;
 }
-
-
-
diff --git a/qcsrc/server/pathlib.qh b/qcsrc/server/pathlib.qh
new file mode 100644 (file)
index 0000000..da4ae0c
--- /dev/null
@@ -0,0 +1,48 @@
+#ifndef PATHLIB_H
+#define PATHLIB_H
+
+//#define PATHLIB_RDFIELDS
+#ifdef PATHLIB_RDFIELDS
+    #define path_next swampslug
+    #define path_prev lasertarget
+#else
+    .entity path_next;
+    .entity path_prev;
+#endif
+
+entity openlist;
+entity closedlist;
+entity scraplist;
+
+.float pathlib_node_g;
+.float pathlib_node_h;
+.float pathlib_node_f;
+
+float pathlib_open_cnt;
+float pathlib_closed_cnt;
+float pathlib_made_cnt;
+float pathlib_merge_cnt;
+float pathlib_recycle_cnt;
+float pathlib_searched_cnt;
+
+float pathlib_bestopen_seached;
+float pathlib_bestcash_hits;
+float pathlib_bestcash_saved;
+
+float pathlib_gridsize;
+
+float pathlib_movecost;
+float pathlib_movecost_diag;
+float pathlib_movecost_waterfactor;
+
+float pathlib_edge_check_size;
+
+float pathlib_foundgoal;
+entity goal_node;
+
+entity best_open_node;
+.float is_path_node;
+
+#define inwater(point) (pointcontents(point) == CONTENT_WATER)
+
+#endif
index 0b2ee4559995671b324050c7664cf0dc2455a5e5..878e8fd5b113fda6f8e03a6fb6f2b04521999d85 100644 (file)
@@ -1,3 +1,5 @@
+#include "../pathlib.qh"
+
 float pathlib_g_static(entity parent,vector to, float static_cost)
 {
     return parent.pathlib_node_g + static_cost;
 float pathlib_g_static(entity parent,vector to, float static_cost)
 {
     return parent.pathlib_node_g + static_cost;
index 4f73b24733bcbf75714a07a33db840cb4e9bc8b6..5c97cf7ac41575adba77f604d88399f000597d95 100644 (file)
@@ -1,3 +1,4 @@
+#include "../pathlib.qh"
 
 #ifdef TURRET_DEBUG
 void mark_error(vector where,float lifetime);
 
 #ifdef TURRET_DEBUG
 void mark_error(vector where,float lifetime);
@@ -65,6 +66,8 @@ void pathlib_showsquare2(entity node ,vector ncolor,float align)
     }
 }
 
     }
 }
 
+void SUB_Remove();
+
 void pathlib_showsquare(vector where,float goodsquare,float _lifetime)
 {
     entity s;
 void pathlib_showsquare(vector where,float goodsquare,float _lifetime)
 {
     entity s;
index 4f9481650ae4b161c7e39dead7c5463c9f71887d..9d49be9ecea3c9a5eb8a5cb75188d56bdfc6ee5a 100644 (file)
@@ -1,3 +1,6 @@
+#include "pathlib.qh"
+#include "utility.qh"
+
 vector plib_points2[8];
 vector plib_points[8];
 float  plib_fvals[8];
 vector plib_points2[8];
 vector plib_points[8];
 float  plib_fvals[8];
index 5fef3251f64b568680f124c442a85572d2ee35c0..bac317e94e29f82b3f53dd882cd2ec0d8c2c8564 100644 (file)
@@ -1,3 +1,9 @@
+#include "../_.qh"
+
+#include "pathlib.qh"
+#include "utility.qh"
+#include "../command/common.qh"
+
 void pathlib_deletepath(entity start)
 {
     entity e;
 void pathlib_deletepath(entity start)
 {
     entity e;
diff --git a/qcsrc/server/pathlib/main.qh b/qcsrc/server/pathlib/main.qh
new file mode 100644 (file)
index 0000000..177c432
--- /dev/null
@@ -0,0 +1,5 @@
+#ifndef PATHLIB_MAIN_H
+#define PATHLIB_MAIN_H
+float buildpath_nodefilter_none(vector n,vector c,vector p);
+entity path_build(entity next, vector where, entity prev, entity start);
+#endif
index 1da6fe16718065a64a0f69ef81767a496399bbaa..884b7951bbe1f4df45f36b486fcedc54c9c78afa 100644 (file)
@@ -1,3 +1,8 @@
+#include "../_.qh"
+
+#include "pathlib.qh"
+#include "utility.qh"
+
 vector pathlib_wateroutnode(vector start,vector end, float doedge)
 {
     vector surface;
 vector pathlib_wateroutnode(vector start,vector end, float doedge)
 {
     vector surface;
index 231c14f21bbbf6b6c8464a62d857ba593394116d..1bc115dc0e49323e033963aa227c9ed4402635bc 100644 (file)
@@ -1,3 +1,8 @@
+#include "../bot/waypoints.qh"
+
+#include "pathlib.qh"
+#include "main.qh"
+
 var float pathlib_wpp_open(entity wp, entity child, float cost);
 
 void pathlib_wpp_close(entity wp)
 var float pathlib_wpp_open(entity wp, entity child, float cost);
 
 void pathlib_wpp_close(entity wp)
index d0029bfc4809be08e2d93195781100a082c755ad..dbf785266ae67a266a1b9d9c4f66ebac245fc60c 100644 (file)
@@ -113,10 +113,4 @@ var float  pathlib_wpp_waypointcallback(entity wp, entity wp_prev);
        #include "debug.qc"
 #endif
 
        #include "debug.qc"
 #endif
 
-#include "utility.qc"
-#include "movenode.qc"
-#include "costs.qc"
-#include "expandnode.qc"
-#include "main.qc"
-#include "path_waypoint.qc"
 #endif
 #endif
index 7bdc70877420a38d60bd7ce7b3da04e99abe4c28..4851dbcc0c52db8a957bf80d2ab85f2762fe80f8 100644 (file)
@@ -1,3 +1,7 @@
+#include "utility.qh"
+
+#include "pathlib.qh"
+
 float fsnap(float val,float fsize)
 {
     return rint(val / fsize) * fsize;
 float fsnap(float val,float fsize)
 {
     return rint(val / fsize) * fsize;
diff --git a/qcsrc/server/pathlib/utility.qh b/qcsrc/server/pathlib/utility.qh
new file mode 100644 (file)
index 0000000..bf72549
--- /dev/null
@@ -0,0 +1,6 @@
+#ifndef PATHLIB_UTILITY
+#define PATHLIB_UTILITY
+float fsnap(float val,float fsize);
+entity pathlib_nodeatpoint(vector where);
+float tile_check_plus2(vector where);
+#endif
index 8d061cdb882b8c43521bdc5863beff1ba03eac90..e82c049a3a476fe90eff551cf1ddf60868c2ca53 100644 (file)
@@ -1,22 +1,18 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/anglestransform.qh"
-    #include "../warpzonelib/util_server.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "autocvars.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "../common/deathtypes.qh"
-    #include "mutators/mutators_include.qh"
-    #include "../csqcmodellib/sv_model.qh"
-    #include "portals.qh"
-    #include "g_hook.qh"
-#endif
+#include "portals.qh"
+#include "_.qh"
+
+#include "g_hook.qh"
+#include "g_subs.qh"
+#include "mutators/mutators_include.qh"
+#include "t_teleporters.qh"
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/notifications.qh"
+#include "../common/util.qh"
+#include "../common/weapons/weapons.qh"
+#include "../csqcmodellib/sv_model.qh"
+#include "../warpzonelib/anglestransform.qh"
+#include "../warpzonelib/util_server.qh"
 
 #define PORTALS_ARE_NOT_SOLID
 
 
 #define PORTALS_ARE_NOT_SOLID
 
index 85e75cda9e2fce18b2f2715b0bd1c10e8452b7bb..f288934a278f9bdc131fc36922e86cfa5e1e0667 100644 (file)
@@ -60,7 +60,16 @@ t_swamp.qc
 t_teleporters.qc
 waypointsprites.qc
 
 t_teleporters.qc
 waypointsprites.qc
 
+bot/aim.qc
 bot/bot.qc
 bot/bot.qc
+bot/navigation.qc
+bot/scripting.qc
+bot/waypoints.qc
+
+bot/havocbot/havocbot.qc
+bot/havocbot/role_keyhunt.qc
+bot/havocbot/role_onslaught.qc
+bot/havocbot/roles.qc
 
 command/banning.qc
 command/cmd.qc
 
 command/banning.qc
 command/cmd.qc
@@ -73,6 +82,13 @@ command/vote.qc
 mutators/mutators_include.qc
 mutators/mutators.qc
 
 mutators/mutators_include.qc
 mutators/mutators.qc
 
+pathlib/costs.qc
+pathlib/expandnode.qc
+pathlib/main.qc
+pathlib/movenode.qc
+pathlib/path_waypoint.qc
+pathlib/utility.qc
+
 weapons/accuracy.qc
 weapons/common.qc
 weapons/csqcprojectile.qc // TODO
 weapons/accuracy.qc
 weapons/common.qc
 weapons/csqcprojectile.qc // TODO
index bb7f0eccc2297ad547b06181fa225d3957ad318d..8e4a5bdc3fefd8b0f4e5b4e9db7145a0ba650c48 100644 (file)
@@ -1,4 +1,18 @@
 #include "race.qh"
 #include "race.qh"
+#include "_.qh"
+
+#include "cl_client.qh"
+#include "portals.qh"
+#include "scores.qh"
+#include "spawnpoints.qh"
+#include "waypointsprites.qh"
+#include "bot/waypoints.qh"
+#include "bot/navigation.qh"
+#include "command/getreplies.qh"
+#include "../common/deathtypes.qh"
+#include "../common/notifications.qh"
+#include "../common/mapinfo.qh"
+#include "../warpzonelib/util_server.qh"
 
 void W_Porto_Fail(float failhard);
 
 
 void W_Porto_Fail(float failhard);
 
@@ -79,7 +93,6 @@ void spawnfunc_target_checkpoint();
 .float race_penalty_accumulator;
 .string race_penalty_reason;
 .float race_checkpoint; // player: next checkpoint that has to be reached
 .float race_penalty_accumulator;
 .string race_penalty_reason;
 .float race_checkpoint; // player: next checkpoint that has to be reached
-.float race_laptime;
 .entity race_lastpenalty;
 
 .entity sprite;
 .entity race_lastpenalty;
 
 .entity sprite;
@@ -176,6 +189,27 @@ void race_send_recordtime(float msg)
        WriteInt24_t(msg, race_readTime(GetMapname(), 1));
 }
 
        WriteInt24_t(msg, race_readTime(GetMapname(), 1));
 }
 
+
+void race_send_speedaward(float msg)
+{
+       // send the best speed of the round
+       WriteByte(msg, SVC_TEMPENTITY);
+       WriteByte(msg, TE_CSQC_RACE);
+       WriteByte(msg, RACE_NET_SPEED_AWARD);
+       WriteInt24_t(msg, floor(speedaward_speed+0.5));
+       WriteString(msg, speedaward_holder);
+}
+
+void race_send_speedaward_alltimebest(float msg)
+{
+       // send the best speed
+       WriteByte(msg, SVC_TEMPENTITY);
+       WriteByte(msg, TE_CSQC_RACE);
+       WriteByte(msg, RACE_NET_SPEED_AWARD_BEST);
+       WriteInt24_t(msg, floor(speedaward_alltimebest+0.5));
+       WriteString(msg, speedaward_alltimebest_holder);
+}
+
 void race_SendRankings(float pos, float prevpos, float del, float msg)
 {
        WriteByte(msg, SVC_TEMPENTITY);
 void race_SendRankings(float pos, float prevpos, float del, float msg)
 {
        WriteByte(msg, SVC_TEMPENTITY);
index bfdc9be4305b80f27265d4c526694a51cfd6ee1e..47c1db4a3860176672e7e9ad486be8cf06a1f181 100644 (file)
@@ -10,6 +10,7 @@ float race_timelimit;
 .float race_place;
 .float race_started;
 .float race_completed;
 .float race_place;
 .float race_started;
 .float race_completed;
+.float race_laptime;
 float race_completing;
 
 .float race_movetime; // for reading
 float race_completing;
 
 .float race_movetime; // for reading
@@ -29,4 +30,26 @@ float race_GetFractionalLapCount(entity e);
 float race_readTime(string map, float pos);
 string race_readUID(string map, float pos);
 string race_readName(string map, float pos);
 float race_readTime(string map, float pos);
 string race_readUID(string map, float pos);
 string race_readName(string map, float pos);
+void race_ClearRecords();
+void race_SendNextCheckpoint(entity e, float spec);
+void race_PreparePlayer();
+void race_send_recordtime(float msg);
+void race_send_speedaward(float msg);
+
+float speedaward_speed;
+string speedaward_holder;
+string speedaward_uid;
+
+float speedaward_alltimebest;
+string speedaward_alltimebest_holder;
+string speedaward_alltimebest_uid;
+
+void race_send_speedaward(float msg);
+
+void race_send_speedaward_alltimebest(float msg);
+
+void race_SendRankings(float pos, float prevpos, float del, float msg);
+
+void race_RetractPlayer();
+
 #endif
 #endif
index 70d2d144d984c5c3220c0d8da9cc7a9c25f159dc..0e6535337e6d688024bc0df54e3b69cfa26b103b 100644 (file)
@@ -1,12 +1,8 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/util.qh"
-    #include "defs.qh"
-    #include "round_handler.qh"
-#endif
+#include "round_handler.qh"
+#include "_.qh"
+
+#include "command/vote.qh"
+#include "../common/util.qh"
 
 void round_handler_Think()
 {
 
 void round_handler_Think()
 {
index a4e3245e6ccef5da4add98d981d992e83d9567a2..19fed17ecd4c1f6e7e52e9d04be1edf02dab511a 100644 (file)
@@ -1,4 +1,10 @@
 #include "scores.qh"
 #include "scores.qh"
+#include "_.qh"
+
+#include "command/common.qh"
+#include "mutators/mutators_include.qh"
+#include "../common/playerstats.qh"
+#include "../common/teams.qh"
 
 .entity scorekeeper;
 entity teamscorekeepers[16];
 
 .entity scorekeeper;
 entity teamscorekeepers[16];
index ff0555cad6cf4d24a27dc9089a327d45dc9bed97..8c9af4534fa1158106727abaf7b52716f4ad0908 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef SCORES_H
 #define SCORES_H
 
 #ifndef SCORES_H
 #define SCORES_H
 
+#include "../common/constants.qh"
+
 entity scores_initialized; // non-world when scores labels/rules have been set
 .float scores[MAX_SCORE];
 .float teamscores[MAX_TEAMSCORE];
 entity scores_initialized; // non-world when scores labels/rules have been set
 .float scores[MAX_SCORE];
 .float teamscores[MAX_TEAMSCORE];
index 4d5296c81603503cafd812c5b5d59c29e1e7786e..e5c426de305adc9bf6e11f60877804a84d098c39 100644 (file)
@@ -1,14 +1,9 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../common/constants.qh"
-    #include "autocvars.qh"
-    #include "defs.qh"
-    #include "scores.qh"
-#endif
-
-//float c1, c2, c3, c4;
+#include "scores_rules.qh"
+#include "_.qh"
+
+#include "cl_client.qh"
+#include "scores.qh"
+
 void CheckAllowedTeams (entity for_whom);
 
 // NOTE: SP_ constants may not be >= MAX_SCORE; ST_constants may not be >= MAX_TEAMSCORE
 void CheckAllowedTeams (entity for_whom);
 
 // NOTE: SP_ constants may not be >= MAX_SCORE; ST_constants may not be >= MAX_TEAMSCORE
diff --git a/qcsrc/server/scores_rules.qh b/qcsrc/server/scores_rules.qh
new file mode 100644 (file)
index 0000000..b307eeb
--- /dev/null
@@ -0,0 +1,8 @@
+#ifndef SCORES_RULES_H
+#define SCORES_RULES_H
+
+void ScoreRules_basics(float teams, float sprio, float stprio, float score_enabled);
+void ScoreRules_basics_end();
+void ScoreRules_generic();
+
+#endif
index 30fbedc4948a27187949b09a43348ed7fe5c9040..853477bb896da56eefa2ec9a8a14acaed84296cc 100644 (file)
@@ -1,11 +1,8 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../common/util.qh"
-    #include "defs.qh"
-    #include "secret.qh"
-#endif
+#include "secret.qh"
+#include "_.qh"
+
+#include "g_triggers.qh"
+#include "../common/util.qh"
 
 void secrets_setstatus() {
        self.stat_secrets_total = secrets_total;
 
 void secrets_setstatus() {
        self.stat_secrets_total = secrets_total;
index 91add1a405b8517a7c61bd05133cdbc085ac25d3..8f656d731f7de4d0ed2646e2cdf0d4767feeb0ab 100644 (file)
@@ -1,19 +1,13 @@
-#if defined(CSQC)
-#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/teams.qh"
-    #include "../common/util.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "mutators/mutators_include.qh"
-    #include "spawnpoints.qh"
-    #include "race.qh"
-#endif
+#include "spawnpoints.qh"
+#include "_.qh"
+
+#include "mutators/mutators_include.qh"
+#include "g_world.qh"
+#include "race.qh"
+#include "../common/constants.qh"
+#include "../common/teams.qh"
+#include "../common/util.qh"
+#include "../warpzonelib/util_server.qh"
 
 float SpawnPoint_Send(entity to, int sf)
 {
 
 float SpawnPoint_Send(entity to, int sf)
 {
index ec76dfef2cda72354df3d1557fdd30e71f19dd7b..f102017b5fc79ce58ae10a4117db276acfe33bc5 100644 (file)
@@ -5,8 +5,6 @@
     #include "../dpdefs/dpextensions.qh"
 #endif
 
     #include "../dpdefs/dpextensions.qh"
 #endif
 
-.vector steerto;
-
 /**
     Uniform pull towards a point
 **/
 /**
     Uniform pull towards a point
 **/
diff --git a/qcsrc/server/steerlib.qh b/qcsrc/server/steerlib.qh
new file mode 100644 (file)
index 0000000..fcd35ba
--- /dev/null
@@ -0,0 +1,10 @@
+#ifndef STEERLIB_H
+#define STEERLIB_H
+
+.vector steerto;
+
+vector steerlib_arrive(vector point,float maximal_distance);
+vector steerlib_attract2(vector point, float min_influense,float max_distance,float max_influense);
+vector steerlib_pull(vector point);
+
+#endif
index c2d3dc7dd855c3eb3f84e6f0dd0efde296a30e09..5779a511dbb4a230af53322461c125a917c43bf5 100644 (file)
@@ -1,26 +1,31 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/common.qh"
-    #include "../warpzonelib/server.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "weapons/csqcprojectile.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/deathtypes.qh"
-    #include "mutators/mutators_include.qh"
-    #include "vehicles/vehicles_def.qh"
-    #include "../common/mapinfo.qh"
-    #include "command/common.qh"
-    #include "../csqcmodellib/sv_model.qh"
-    #include "anticheat.qh"
-    #include "g_hook.qh"
-#endif
+#include "_.qh"
+
+#include "anticheat.qh"
+#include "g_hook.qh"
+#include "g_world.qh"
+
+#include "bot/bot.qh"
+#include "bot/waypoints.qh"
+
+#include "command/common.qh"
+
+#include "mutators/mutators_include.qh"
+#include "vehicles/vehicles_def.qh"
+#include "weapons/csqcprojectile.qh"
+
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/mapinfo.qh"
+#include "../common/util.qh"
+
+#include "../common/weapons/weapons.qh"
+
+#include "../csqcmodellib/sv_model.qh"
+
+#include "../warpzonelib/common.qh"
+#include "../warpzonelib/server.qh"
+
+.float lastground;
 
 void CreatureFrame (void)
 {
 
 void CreatureFrame (void)
 {
index 681c5dc7d3f0998788b485baf38bd495d49a9682..754c52b49ab70996ef9c96a56c596a1c4ae3a869 100644 (file)
@@ -1,11 +1,10 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../warpzonelib/util_server.qh"
-    #include "defs.qh"
-    #include "vehicles/vehicles_def.qh"
-#endif
+#include "_.qh"
+
+#include "../warpzonelib/util_server.qh"
+#include "vehicles/vehicles_def.qh"
+
+.float  ladder_time;
+.entity ladder_entity;
 
 .float  roomtype;
 .float  radius;
 
 .float  roomtype;
 .float  radius;
index 8a5ac17b1a1d73cdc699b4d367673232012e5dc5..a68354a1ab315192e9dd9c3a8fe922785b99c440 100644 (file)
@@ -1,12 +1,18 @@
 #include "t_items.qh"
 
 #if defined(SVQC)
 #include "t_items.qh"
 
 #if defined(SVQC)
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
+    #include "_.qh"
+
+    #include "g_subs.qh"
+    #include "waypointsprites.qh"
+
+    #include "bot/bot.qh"
+    #include "bot/waypoints.qh"
 
     #include "mutators/mutators_include.qh"
 
 
     #include "mutators/mutators_include.qh"
 
+    #include "weapons/common.qh"
+    #include "weapons/selection.qh"
     #include "weapons/weaponsystem.qh"
 
     #include "../common/constants.qh"
     #include "weapons/weaponsystem.qh"
 
     #include "../common/constants.qh"
@@ -18,9 +24,6 @@
 
     #include "../common/weapons/weapons.qh"
 
 
     #include "../common/weapons/weapons.qh"
 
-    #include "../dpdefs/dpextensions.qh"
-    #include "../dpdefs/progsdefs.qh"
-
     #include "../warpzonelib/util_server.qh"
 #endif
 
     #include "../warpzonelib/util_server.qh"
 #endif
 
index ae4ecdb769375b17065136d95373c6411a9f7296..429f3c311f31099048c2f309d0c704a612d6ce96 100644 (file)
@@ -63,6 +63,10 @@ const int ISF_SIZE                           = 128;
 
 .int ItemStatus;
 
 
 .int ItemStatus;
 
+void spawnfunc_item_strength();
+void spawnfunc_item_invincible();
+void spawnfunc_item_armor_small();
+
 #ifdef CSQC
 
 float  autocvar_cl_animate_items = 1;
 #ifdef CSQC
 
 float  autocvar_cl_animate_items = 1;
index 92af1cdd093b0733fe922e4423d96da706693457..018a7c259c9f0ab24aeb90dcf2bb9866a357b63b 100644 (file)
@@ -1,4 +1,16 @@
 #include "t_jumppads.qh"
 #include "t_jumppads.qh"
+#include "_.qh"
+
+#include "g_subs.qh"
+
+#include "bot/navigation.qh"
+#include "bot/waypoints.qh"
+
+#include "weapons/csqcprojectile.qh"
+
+#include "../common/animdecide.qh"
+
+#include "../warpzonelib/util_server.qh"
 
 void trigger_push_use()
 {
 
 void trigger_push_use()
 {
index ebe1676c777d2136074b831d13c4b159d6ad7c58..73bc327ceef1ff51b73dc73fcd81a9840312c707 100644 (file)
@@ -1,21 +1,27 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../warpzonelib/mathlib.qh"
-    #include "../warpzonelib/common.qh"
-    #include "../warpzonelib/util_server.qh"
-    #include "../common/constants.qh"
-    #include "../common/util.qh"
-    #include "../common/weapons/weapons.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-    #include "../common/notifications.qh"
-    #include "../common/deathtypes.qh"
-    #include "command/common.qh"
-    #include "../csqcmodellib/sv_model.qh"
-#endif
+#include "_.qh"
+
+#include "bot/bot.qh"
+
+#include "command/common.qh"
+
+#include "g_damage.qh"
+#include "g_subs.qh"
+#include "item_key.qh"
+
+#include "../common/constants.qh"
+#include "../common/deathtypes.qh"
+#include "../common/notifications.qh"
+#include "../common/util.qh"
+
+#include "../common/weapons/weapons.qh"
+
+#include "../csqcmodellib/sv_model.qh"
+
+#include "../warpzonelib/common.qh"
+#include "../warpzonelib/mathlib.qh"
+#include "../warpzonelib/util_server.qh"
+
+.float height;
 
 .float dmgtime2;
 void generic_plat_blocked()
 
 .float dmgtime2;
 void generic_plat_blocked()
index 9b25c8860905440b3b724ec09c261a6fcfbbc14a..b81e0c07d1ccb817938c0f8813c56d702ff1f7df 100644 (file)
@@ -1,3 +1,5 @@
+#include "_.qh"
+
 #include "../common/weapons/weapons.qc"
 
 //***********************
 #include "../common/weapons/weapons.qc"
 
 //***********************
index ed90bf054c0c1aeeed5668afd43c3b3e0eb09d26..3a67bc1fd5cfd9c215738e2fb3f1dd94f42d418b 100644 (file)
@@ -1,3 +1,5 @@
+#include "_.qh"
+
 #include "../common/weapons/weapons.qc"
 
 //***********************
 #include "../common/weapons/weapons.qc"
 
 //***********************
index b63e7ffe31ee332ffc61c2f3eb5b789dbdf5ff97..9176f61b06cbc5b6832c1be9d4a52c55820ba773 100644 (file)
@@ -1,10 +1,10 @@
 #if defined(CSQC)
 #elif defined(MENUQC)
 #elif defined(SVQC)
 #if defined(CSQC)
 #elif defined(MENUQC)
 #elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
+       #include "_.qh"
+
     #include "../warpzonelib/util_server.qh"
     #include "../common/weapons/weapons.qh"
     #include "../warpzonelib/util_server.qh"
     #include "../common/weapons/weapons.qh"
-    #include "defs.qh"
     #include "../common/deathtypes.qh"
 #endif
 
     #include "../common/deathtypes.qh"
 #endif
 
index 46df0eb78636d45f82d5cab7e64ff1f2cdfa412f..5a013b7d3c086e167e213e9ddc8ac3289390e324 100644 (file)
@@ -1,4 +1,5 @@
 #include "t_teleporters.qh"
 #include "t_teleporters.qh"
+#include "_.qh"
 
 #if defined(CSQC)
 #elif defined(MENUQC)
 
 #if defined(CSQC)
 #elif defined(MENUQC)
@@ -9,9 +10,6 @@
     #include "../common/constants.qh"
     #include "../common/util.qh"
     #include "weapons/csqcprojectile.qh"
     #include "../common/constants.qh"
     #include "../common/util.qh"
     #include "weapons/csqcprojectile.qh"
-    #include "autocvars.qh"
-    #include "constants.qh"
-    #include "defs.qh"
     #include "../common/deathtypes.qh"
     #include "tturrets/include/turrets_early.qh"
     #include "vehicles/vehicles_def.qh"
     #include "../common/deathtypes.qh"
     #include "tturrets/include/turrets_early.qh"
     #include "vehicles/vehicles_def.qh"
index be476d758fec7c264d94a43c996885483ab78e36..12ee04ad22ba1567f1281360ac04002f285b3b24 100644 (file)
@@ -1,13 +1,6 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/constants.qh"
-    #include "constants.qh"
-    #include "defs.qh"
-#endif
+#include "_.qh"
 
 
+.float volume;
 .float lifetime;
 // values:
 //   volume
 .float lifetime;
 // values:
 //   volume
index cba5f365d5c60424b40bb332abf61223965d7b1e..e89b5c0c517de1d63bd0cb53d7a50301fe618382 100644 (file)
@@ -1,11 +1,7 @@
-#if defined(CSQC)
-#elif defined(MENUQC)
-#elif defined(SVQC)
-       #include "../dpdefs/progsdefs.qh"
-    #include "../dpdefs/dpextensions.qh"
-    #include "../common/util.qh"
-    #include "defs.qh"
-#endif
+#include "_.qh"
+
+.entity pusher;
+.float pushltime;
 
 // spawner entity
 // "classname" "target_spawn"
 
 // spawner entity
 // "classname" "target_spawn"
index ba1b4e6eedacb91412044bd0529c472ac3ffb977..7301cf9e0814f6bee6942a905bf74dd658144f00 100644 (file)
@@ -1,4 +1,19 @@
 #include "teamplay.qh"
 #include "teamplay.qh"
+#include "_.qh"
+
+#include "cl_client.qh"
+#include "race.qh"
+#include "scores.qh"
+#include "scores_rules.qh"
+
+#include "bot/bot.qh"
+
+#include "command/vote.qh"
+
+#include "mutators/mutators_include.qh"
+
+#include "../common/deathtypes.qh"
+#include "../common/teams.qh"
 
 void TeamchangeFrags(entity e)
 {
 
 void TeamchangeFrags(entity e)
 {
index ad0b68521bb4c03f46991e3cc331e37ea7740cd5..b8cfea267547de536fa0d3e1767ba7fa7ab1386e 100644 (file)
@@ -1,3 +1,8 @@
+#include "../../_.qh"
+
+#include "../../g_damage.qh"
+#include "../../bot/bot.qh"
+
 #define cvar_base "g_turrets_unit_"
 .float clientframe;
 void turrets_setframe(float _frame, float client_only)
 #define cvar_base "g_turrets_unit_"
 .float clientframe;
 void turrets_setframe(float _frame, float client_only)
index 7eb1622baf102b80fd1aba8407559613c6b10bf5..4133ae97df5043fd277ede7d07fe17c5472a9e1f 100644 (file)
@@ -1,3 +1,5 @@
+#include "../../bot/navigation.qh"
+
 const float ewheel_amin_stop = 0;
 const float ewheel_amin_fwd_slow = 1;
 const float ewheel_amin_fwd_fast = 2;
 const float ewheel_amin_stop = 0;
 const float ewheel_amin_fwd_slow = 1;
 const float ewheel_amin_fwd_fast = 2;
index d235dfb32787124cdaf946b6bd59ff5178549db4..21c6acfccef7d55e25928e2a8111dc0717fda136 100644 (file)
@@ -1,3 +1,5 @@
+void W_MachineGun_MuzzleFlash(void);
+
 void spawnfunc_turret_machinegun();
 void turret_machinegun_std_init();
 void turret_machinegun_attack();
 void spawnfunc_turret_machinegun();
 void turret_machinegun_std_init();
 void turret_machinegun_attack();
index a5aafda8f84d0589c112ff0d68950801f4a7ddec..33aa484bafd878cfd7fea96a5595067a47baef27 100644 (file)
@@ -1,3 +1,5 @@
+#include "../../_.qh"
+
 void spawnfunc_turret_phaser();
 void turret_phaser_dinit();
 void turret_phaser_attack();
 void spawnfunc_turret_phaser();
 void turret_phaser_dinit();
 void turret_phaser_attack();
index 0f2de3c869ab1a96fe43328c54f7f4627d018248..205cd0b5311eb8c15bc82e9d149cdc3ee507283e 100644 (file)
@@ -1,3 +1,5 @@
+#include "../../g_subs.qh"
+
 void spawnfunc_turret_targettrigger();
 void turret_targettrigger_touch();
 
 void spawnfunc_turret_targettrigger();
 void turret_targettrigger_touch();
 
index 4989b2445efc99808dab32b75b29935cdd46e95a..c95de1373ab7317ba979800ce6c58e03fb38b52d 100644 (file)
@@ -1,3 +1,5 @@
+#include "../../csqceffects.qh"
+
 void spawnfunc_turret_tesla();
 void turret_tesla_dinit();
 void turret_tesla_fire();
 void spawnfunc_turret_tesla();
 void turret_tesla_dinit();
 void turret_tesla_fire();
index f76d119230514283fad3d59447ca2c3488a94b0d..16141064ead995f2db759125a5cb3384c40fb86a 100644 (file)
@@ -1,3 +1,9 @@
+#include "../../_.qh"
+
+#include "../../movelib.qh"
+#include "../../steerlib.qh"
+#include "../../t_teleporters.qh"
+
 const float ANIM_NO         = 0;
 const float ANIM_TURN       = 1;
 const float ANIM_WALK       = 2;
 const float ANIM_NO         = 0;
 const float ANIM_TURN       = 1;
 const float ANIM_WALK       = 2;
index c9edecf56cbecc190c20963695f47ae6c5f56ffb..dfbcd4c36e7150884d9b15ca455aa68311543472 100644 (file)
@@ -323,6 +323,7 @@ void bumb_regen()
 
 }
 
 
 }
 
+.vector hook_start, hook_end;
 float bumb_pilot_frame()
 {
        entity pilot, vehic;
 float bumb_pilot_frame()
 {
        entity pilot, vehic;
index b96419584b50f2924cc11b501f85d42847006549..49cebfc46bc8e1695acb665496ca3a453a11513d 100644 (file)
@@ -447,6 +447,8 @@ float racer_frame()
     return 1;
 }
 
     return 1;
 }
 
+.float lastpushtime;
+
 void racer_think()
 {
     self.nextthink = time;
 void racer_think()
 {
     self.nextthink = time;
index 5e6bf8dfbea5552558168121359a1838f482de65..3778b040553548ccbb5aea806372972f7742c809 100644 (file)
@@ -1,3 +1,12 @@
+#include "vehicles.qh"
+
+#include "../cl_player.qh"
+#include "../waypointsprites.qh"
+
+#include "../bot/waypoints.qh"
+
+.float() PlayerPhysplug;
+
 float autocvar_g_vehicles_crush_dmg;
 float autocvar_g_vehicles_crush_force;
 float autocvar_g_vehicles_delayspawn;
 float autocvar_g_vehicles_crush_dmg;
 float autocvar_g_vehicles_crush_force;
 float autocvar_g_vehicles_delayspawn;
index 7af726f4c8dec00182a6ea83c46cf958d10113f7..09539c6d7e741c0d2ed475734aca092b97c666cb 100755 (executable)
@@ -3,6 +3,11 @@ set -eu
 cd "$(dirname "$0")"
 cd ..
 
 cd "$(dirname "$0")"
 cd ..
 
+declare -a NOWARN=(
+  '-Wno-field-redeclared'
+  '-Wno-unused-variable'
+  '-Wno-implicit-function-pointer'
+)
 declare QCC=../../../gmqcc/gmqcc
 
 function check() {
 declare QCC=../../../gmqcc/gmqcc
 
 function check() {
@@ -10,15 +15,15 @@ function check() {
   declare -la predefs=("${!2}")
   find "$base" -type f -name '*.qc' -print0 | sort -z | while IFS= read -r -d '' file; do
     echo "$file"
   declare -la predefs=("${!2}")
   find "$base" -type f -name '*.qc' -print0 | sort -z | while IFS= read -r -d '' file; do
     echo "$file"
-    ${QCC} -std=gmqcc -fftepp -fftepp-predefs -futf8 -O3 "${predefs[@]}" "$file" >/dev/null
+    ${QCC} -std=gmqcc -fftepp -fftepp-predefs -Werror -Wall "${NOWARN[@]}" -futf8 -O3 "${predefs[@]}" "$file" >/dev/null
   done
 }
 
 clientdefs=("-DCSQC" "common/util-pre.qh" "dpdefs/csprogsdefs.qh")
 check "client" clientdefs[@]
 
   done
 }
 
 clientdefs=("-DCSQC" "common/util-pre.qh" "dpdefs/csprogsdefs.qh")
 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[@]
+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[@]
 
 # menudefs=("-DMENUQC" "common/util-pre.qh" "dpdefs/menudefs.qh" "menu/oo/interface.qc" "menu/oo/implementation.qc")
 # check "menu" menudefs[@]