]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc
phisics.qc: fix indentation; sv_onslaught.qc: move clientcamera_send next to cam...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / gamemodes / gamemode / onslaught / sv_onslaught.qc
index 8d9ad2e11b7c653effa52b745f8147b404d44146..b285d17f4d96077384a1595f0190471965d305fd 100644 (file)
@@ -36,23 +36,10 @@ float autocvar_g_onslaught_teleport_radius;
 float autocvar_g_onslaught_spawn_choose;
 float autocvar_g_onslaught_click_radius;
 
-entity cam;
-
 // =======================
 // CaptureShield Functions
 // =======================
 
-bool clientcamera_send(entity this, entity to, int sf)
-{
-       WriteHeader(MSG_ENTITY, ENT_ONSCAMERA);
-
-       WriteVector(MSG_ENTITY, this.origin);
-
-       WriteAngleVector(MSG_ENTITY, this.angles);
-
-       return true;
-}
-
 bool ons_CaptureShield_Customize(entity this, entity client)
 {
        entity e = WaypointSprite_getviewentity(client);
@@ -327,14 +314,15 @@ int ons_ControlPoint_CanBeLinked(entity cp, int teamnum)
        return 0;
 }
 
+// return values:
+// -2: SAME TEAM, attackable by enemy!
+// -1: SAME TEAM!
+// 0: off limits
+// 1: attack it
+// 2: touch it
+// 3: attack it (HIGH PRIO)
+// 4: touch it (HIGH PRIO)
 int ons_ControlPoint_Attackable(entity cp, int teamnum)
-       // -2: SAME TEAM, attackable by enemy!
-       // -1: SAME TEAM!
-       // 0: off limits
-       // 1: attack it
-       // 2: touch it
-       // 3: attack it (HIGH PRIO)
-       // 4: touch it (HIGH PRIO)
 {
        int a;
 
@@ -854,6 +842,15 @@ void ons_Generator_UpdateSprite(entity e)
        }
 }
 
+entity cam;
+bool clientcamera_send(entity this, entity to, int sf)
+{
+       WriteHeader(MSG_ENTITY, ENT_ONSCAMERA);
+       WriteVector(MSG_ENTITY, this.origin);
+       WriteAngleVector(MSG_ENTITY, this.angles);
+       return true;
+}
+
 void ons_camSetup(entity this)
 {
        vector dir;