mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-07-14 15:44:34 +00:00
Changed Method
This commit is contained in:
parent
d2f38aac33
commit
ab761f0922
1 changed files with 6 additions and 16 deletions
|
|
@ -45,28 +45,18 @@ function GetTeamCounts( %game, %client, %respawn )
|
||||||
//Get teamcounts
|
//Get teamcounts
|
||||||
if($countdownStarted && $MatchStarted )
|
if($countdownStarted && $MatchStarted )
|
||||||
{
|
{
|
||||||
//Team Count code by Keen
|
//Variables
|
||||||
$PlayerCount[0] = 0;
|
$PlayerCount[1] = $TeamRank[1, count];
|
||||||
$PlayerCount[1] = 0;
|
$PlayerCount[2] = $TeamRank[2, count];
|
||||||
$PlayerCount[2] = 0;
|
$PlayerCount[0] = $HostGamePlayerCount - ($PlayerCount[1] + $PlayerCount[2]);
|
||||||
|
|
||||||
for(%i = 0; %i < ClientGroup.getCount(); %i++)
|
|
||||||
{
|
|
||||||
%client = ClientGroup.getObject(%i);
|
|
||||||
|
|
||||||
//if(!%client.isAIControlled())
|
|
||||||
$PlayerCount[%client.team]++;
|
|
||||||
}
|
|
||||||
|
|
||||||
//echo ("$PlayerCount[0] " @ $PlayerCount[0]);
|
//echo ("$PlayerCount[0] " @ $PlayerCount[0]);
|
||||||
//echo ("$PlayerCount[1] " @ $PlayerCount[1]);
|
//echo ("$PlayerCount[1] " @ $PlayerCount[1]);
|
||||||
//echo ("$PlayerCount[2] " @ $PlayerCount[2]);
|
//echo ("$PlayerCount[2] " @ $PlayerCount[2]);
|
||||||
|
|
||||||
//Amount of players on teams
|
|
||||||
$TotalTeamPlayerCount = $PlayerCount[1] + $PlayerCount[2];
|
$TotalTeamPlayerCount = $PlayerCount[1] + $PlayerCount[2];
|
||||||
//Amount of all players including observers
|
$AllPlayerCount = $HostGamePlayerCount;
|
||||||
$AllPlayerCount = $PlayerCount[1] + $PlayerCount[2] + $PlayerCount[0];
|
|
||||||
//Difference Variables
|
|
||||||
%team1difference = $PlayerCount[1] - $PlayerCount[2];
|
%team1difference = $PlayerCount[1] - $PlayerCount[2];
|
||||||
%team2difference = $PlayerCount[2] - $PlayerCount[1];
|
%team2difference = $PlayerCount[2] - $PlayerCount[1];
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue