]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge remote branch 'origin/master' into samual/mutator_ctf
authorSamual <samual@xonotic.org>
Tue, 26 Apr 2011 03:31:39 +0000 (23:31 -0400)
committerSamual <samual@xonotic.org>
Tue, 26 Apr 2011 03:31:39 +0000 (23:31 -0400)
1  2 
qcsrc/server/autocvars.qh
qcsrc/server/cl_client.qc
qcsrc/server/defs.qh

index 99bdd3a4b7cde1c3faf24afe7c69201b389b63be,2a99f50323fe01ea43ae1b837d6a56956ecbf4dc..ae15b2b4e2443ad3890dc79298b74ae28260c9cf
@@@ -54,6 -54,9 +54,9 @@@ float autocvar_bot_sound_monopoly
  #define autocvar_bot_suffix cvar_string("bot_suffix")
  float autocvar_bot_usemodelnames;
  float autocvar_bot_vs_human;
+ float autocvar_bot_debug_tracewalk;
+ float autocvar_bot_debug_goalstack;
+ float autocvar_bot_wander_enable;
  float autocvar_captureleadlimit_override;
  #define autocvar_capturelimit_override cvar("capturelimit_override")
  float autocvar_deathmatch_force_teamplay;
@@@ -93,6 -96,7 +96,7 @@@ float autocvar_g_balance_sniperrifle_pr
  float autocvar_g_balance_sniperrifle_primary_headshotaddeddamage;
  float autocvar_g_balance_sniperrifle_primary_lifetime;
  float autocvar_g_balance_sniperrifle_primary_refire;
+ float autocvar_g_balance_sniperrifle_primary_shots;
  float autocvar_g_balance_sniperrifle_primary_speed;
  float autocvar_g_balance_sniperrifle_primary_spread;
  float autocvar_g_balance_sniperrifle_primary_tracer;
@@@ -108,6 -112,7 +112,7 @@@ float autocvar_g_balance_sniperrifle_se
  float autocvar_g_balance_sniperrifle_secondary_lifetime;
  float autocvar_g_balance_sniperrifle_secondary_reload;
  float autocvar_g_balance_sniperrifle_secondary_refire;
+ float autocvar_g_balance_sniperrifle_secondary_shots;
  float autocvar_g_balance_sniperrifle_secondary_speed;
  float autocvar_g_balance_sniperrifle_secondary_spread;
  float autocvar_g_balance_sniperrifle_secondary_tracer;
@@@ -728,7 -733,6 +733,7 @@@ float autocvar_g_ctf_flag_blue_skin
  float autocvar_g_ctf_flag_capture_effects;
  float autocvar_g_ctf_flag_glowtrails;
  float autocvar_g_ctf_flag_pickup_effects;
 +float autocvar_g_ctf_flag_pickup_verbosename;
  string autocvar_g_ctf_flag_red_model;
  float autocvar_g_ctf_flag_red_skin;
  float autocvar_g_ctf_flag_returntime;
index a07b2330ca913c5d8a0d69bf1e7d72f642ae6d8d,9e704b882486ad3cdadb5eb2c2834c282f2e8a7c..ed3027a194d1fee080b12c663e37301da8729b9a
@@@ -328,13 -328,28 +328,28 @@@ entity SelectSpawnPoint (float anypoint
        if(anypoint)
                teamcheck = -1;
        else if(have_team_spawns > 0)
-               teamcheck = self.team; // MUST be team
-       else if(have_team_spawns == 0 && have_noteam_spawns)
+       {
+               if(have_team_spawns_forteam[self.team] == 0)
+               {
+                       // we request a spawn for a team, and we have team
+                       // spawns, but that team has no spawns?
+                       if(have_team_spawns[0])
+                               // try noteam spawns
+                               teamcheck = 0;
+                       else
+                               // if not, any spawn has to do
+                               teamcheck = -1;
+               }
+               else
+                       teamcheck = self.team; // MUST be team
+       }
+       else if(have_team_spawns == 0 && have_team_spawns[0])
                teamcheck = 0; // MUST be noteam
        else
                teamcheck = -1;
                // if we get here, we either require team spawns but have none, or we require non-team spawns and have none; use any spawn then
  
        // get the list of players
        playerlist = findchain(classname, "player");
        // get the entire list of spots
@@@ -608,7 -623,7 +623,7 @@@ void PutObserverInServer (void
        }
  
        if(self.flagcarried)
 -              DropFlag(self.flagcarried, world, world);
 +              ctf_Handle_Drop(self); // FIXCTF
  
        if(self.ballcarried && g_nexball)
                DropBall(self.ballcarried, self.origin + self.ballcarried.origin, self.velocity);
@@@ -1805,7 -1820,7 +1820,7 @@@ void ClientDisconnect (void
        Portal_ClearAll(self);
  
        if(self.flagcarried)
 -              DropFlag(self.flagcarried, world, world);
 +              ctf_Handle_Drop(self); // FIXCTF
        if(self.ballcarried && g_nexball)
                DropBall(self.ballcarried, self.origin + self.ballcarried.origin, self.velocity);
  
@@@ -2609,7 -2624,7 +2624,7 @@@ PlayerPreThin
  Called every frame for each client before the physics are run
  =============
  */
 -void() ctf_setstatus;
 +//void() ctf_setstatus;
  void() nexball_setstatus;
  .float items_added;
  void PlayerPreThink (void)
                        return;                                 // the think tics
                }
  
-               if(self.teleport_time)
-               if(time > self.teleport_time)
-               {
-                       self.teleport_time = 0;
-                       self.effects = self.effects - (self.effects & EF_NODRAW);
-               }
                if(frametime > 0) // don't do this in cl_movement frames, just in server ticks
                        UpdateSelectedPlayer();
  
                if (g_minstagib)
                        minstagib_ammocheck();
  
 -              if(g_ctf)
 -                      ctf_setstatus();
 +              //if(g_ctf)
 +              //      ctf_setstatus();
  
                if(g_nexball)
                        nexball_setstatus();
diff --combined qcsrc/server/defs.qh
index 8b79374267a895576fd412d3e045700969e563d7,cf13fee2c67cc944407e4921e3ee79af2f225cc8..97fbfb53cec7dfdb0a9c4462a7f521db0eb4aee2
@@@ -15,7 -15,7 +15,7 @@@ float require_spawnfunc_prefix; // if t
  
  // Globals
  
 -float ctf_score_value(string parameter);
 +float ctf_ReadScore(string parameter); // SOON WON'T BE NEEDED. // FIXCTF
  
  float g_dm, g_domination, g_ctf, g_tdm, g_keyhunt, g_onslaught, g_assault, g_arena, g_ca, g_lms, g_runematch, g_race, g_nexball, g_cts, g_freezetag, g_keepaway;
  float g_cloaked, g_footsteps, g_jump_grunt, g_grappling_hook, g_midair, g_minstagib, g_pinata, g_norecoil, g_minstagib_invis_alpha, g_bloodloss;
@@@ -350,7 -350,7 +350,7 @@@ float teams_matter
  
  float startitem_failed;
  
 -void DropFlag(entity flag, entity penalty_receiver, entity attacker);
 +void ctf_Handle_Drop(entity player); // FIXCTF
  void DropBall(entity ball, vector org, vector vel);
  void DropAllRunes(entity pl);
  
@@@ -410,7 -410,7 +410,7 @@@ float TemporaryDB
  
  float some_spawn_has_been_used;
  float have_team_spawns; // 0 = no team spawns requested, -1 = team spawns requested but none found, 1 = team spawns requested and found
- float have_noteam_spawns; // 0 = no no-team spawns, 1 = no-team spawns exist
+ float have_team_spawns_forteam[17]; // 0 = this team has no spawns, 1 = this team has spawns; team 0 is the "no-team"
  
  // set when showing a kill countdown
  .entity killindicator;