mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-07-15 16:14:35 +00:00
Update Autobalance.cs
This commit is contained in:
parent
f72e3dcfd1
commit
edad129836
1 changed files with 10 additions and 10 deletions
|
|
@ -61,9 +61,6 @@ function Autobalance( %game )
|
||||||
//Select lower half of team rank as canidates for team change
|
//Select lower half of team rank as canidates for team change
|
||||||
if(!$Autobalance::UseAllMode)
|
if(!$Autobalance::UseAllMode)
|
||||||
{
|
{
|
||||||
//Reset clients canidate var
|
|
||||||
ResetABClients();
|
|
||||||
|
|
||||||
$Autobalance::Max = mFloor($TeamRank[$BigTeam, count]/2);
|
$Autobalance::Max = mFloor($TeamRank[$BigTeam, count]/2);
|
||||||
for(%i = $Autobalance::Max; %i < $TeamRank[$BigTeam, count]; %i++)
|
for(%i = $Autobalance::Max; %i < $TeamRank[$BigTeam, count]; %i++)
|
||||||
{
|
{
|
||||||
|
|
@ -127,14 +124,17 @@ function DefaultGame::gameOver(%game)
|
||||||
{
|
{
|
||||||
Parent::gameOver(%game);
|
Parent::gameOver(%game);
|
||||||
|
|
||||||
//Reset Autobalance
|
if($CurrentMissionType $= "CTF" || $CurrentMissionType $= "SCtF")
|
||||||
$BigTeam = "";
|
|
||||||
|
|
||||||
//Reset all clients canidate var
|
|
||||||
for (%i = 0; %i < ClientGroup.getCount(); %i++)
|
|
||||||
{
|
{
|
||||||
%client = ClientGroup.getObject(%i);
|
//Reset Autobalance
|
||||||
%client.abCanidate = false;
|
$BigTeam = "";
|
||||||
|
|
||||||
|
//Reset all clients canidate var
|
||||||
|
for (%i = 0; %i < ClientGroup.getCount(); %i++)
|
||||||
|
{
|
||||||
|
%client = ClientGroup.getObject(%i);
|
||||||
|
%client.abCanidate = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue