X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fteamplay.qc;h=c5a079f8b50978b682a06744399f5db958f44a7c;hb=6361453ce9dd1b4978e8fa36412ea4e0128cbdee;hp=16236dd16ba7d93fb52210553efe8d0ca89a5078;hpb=1633673cc6c65bdca0120f2a4fc33e8c2449f06d;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/teamplay.qc b/qcsrc/server/teamplay.qc index 16236dd16..c5a079f8b 100644 --- a/qcsrc/server/teamplay.qc +++ b/qcsrc/server/teamplay.qc @@ -270,9 +270,7 @@ string getwelcomemessage(void) ret_string = ""; MUTATOR_CALLHOOK(BuildMutatorsPrettyString); modifications = ret_string; - - if(g_minstagib) - modifications = strcat(modifications, ", MinstaGib"); + if(g_weaponarena) { if(g_weaponarena_random) @@ -408,8 +406,8 @@ void CheckAllowedTeams (entity for_whom) } else if(g_domination) teament_name = "dom_team"; - else if(g_ctf) - teament_name = "ctf_team"; + //else if(g_ctf) + //teament_name = "ctf_team"; else if(g_tdm) teament_name = "tdm_team"; else if(g_nexball) @@ -464,7 +462,7 @@ void CheckAllowedTeams (entity for_whom) if(autocvar_bot_vs_human > 0) { // bots are all blue - if(clienttype(for_whom) == CLIENTTYPE_BOT) + if(IS_BOT_CLIENT(for_whom)) c1 = c3 = c4 = -1; else c2 = -1; @@ -472,7 +470,7 @@ void CheckAllowedTeams (entity for_whom) else { // bots are all red - if(clienttype(for_whom) == CLIENTTYPE_BOT) + if(IS_BOT_CLIENT(for_whom)) c2 = c3 = c4 = -1; else c1 = -1; @@ -510,7 +508,7 @@ void GetTeamCounts(entity ignore) FOR_EACH_CLIENT(head) { float t; - if(head.classname == "player") + if(IS_PLAYER(head)) t = head.team; else if(head.team_forced > 0) t = head.team_forced; // reserve the spot @@ -519,7 +517,7 @@ void GetTeamCounts(entity ignore) if(head != ignore)// && head.netname != "") { value = PlayerValue(head); - if(clienttype(head) == CLIENTTYPE_BOT) + if(IS_BOT_CLIENT(head)) bvalue = value; else bvalue = 0; @@ -600,7 +598,7 @@ float TeamSmallerEqThanTeam(float ta, float tb, entity e) if(ta == tb) return TRUE; - if(clienttype(e) == CLIENTTYPE_REAL) + if(IS_REAL_CLIENT(e)) { if(bots_would_leave) { @@ -658,7 +656,7 @@ float FindSmallestTeam(entity pl, float ignore_pl) if(totalteams <= 1) { - if(autocvar_g_campaign && pl && clienttype(pl) == CLIENTTYPE_REAL) + if(autocvar_g_campaign && pl && IS_REAL_CLIENT(pl)) return 1; // special case for campaign and player joining else if(g_domination) error("Too few teams available for domination\n"); @@ -841,7 +839,7 @@ void SV_ChangeTeam(float _color) // bprint("allow change teams from ", ftos(steam), " to ", ftos(dteam), "\n"); - if(self.classname == "player" && steam != dteam) + if(IS_PLAYER(self) && steam != dteam) { // reduce frags during a team change TeamchangeFrags(self); @@ -849,7 +847,7 @@ void SV_ChangeTeam(float _color) SetPlayerTeam(self, dteam, steam, FALSE); - if(self.classname == "player" && steam != dteam) + if(IS_PLAYER(self) && steam != dteam) { // kill player when changing teams if(self.deadflag == DEAD_NO)