fix rounds counter in cup mode
This commit is contained in:
parent
89d591a13f
commit
85254384b5
@ -1376,8 +1376,9 @@ class MatchManagerCore implements CallbackListener, CommandListener, TimerListen
|
|||||||
|
|
||||||
if ($this->currentgmbase == "Champion") {
|
if ($this->currentgmbase == "Champion") {
|
||||||
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, $points , $result->getMapPoints(), $time, "")));
|
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, $points , $result->getMapPoints(), $time, "")));
|
||||||
} elseif ($this->currentgmbase == "Cup") {
|
} elseif ($this->currentgmbase == "Cup") {
|
||||||
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, ($points + $roundpoints), $roundpoints, $time, "-1")));
|
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, ($points + $roundpoints), $roundpoints, $time, "-1")));
|
||||||
|
if ($roundpoints > 0) $atleastonefinished = true; // Round is skipped if no one finishes only in cup mode
|
||||||
} elseif ($this->currentgmbase == "Rounds" ) {
|
} elseif ($this->currentgmbase == "Rounds" ) {
|
||||||
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, ($points + $roundpoints), $roundpoints, $time, "-1")));
|
$this->currentscore = array_merge($this->currentscore, array(array($rank, $player->login, ($points + $roundpoints), $roundpoints, $time, "-1")));
|
||||||
} elseif ($this->currentgmbase == "Teams") {
|
} elseif ($this->currentgmbase == "Teams") {
|
||||||
@ -1403,7 +1404,9 @@ class MatchManagerCore implements CallbackListener, CommandListener, TimerListen
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!$this->pauseon && !$this->skipround) {
|
if (!$this->pauseon && !$this->skipround) {
|
||||||
$this->nbrounds++;
|
if ($this->currentgmbase != "Cup" || ($this->currentgmbase == "Cup" && isset($atleastonefinished) && $atleastonefinished)) { // Round is skipped if no one finishes only in cup mode
|
||||||
|
$this->nbrounds++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if ($this->skipround) {
|
if ($this->skipround) {
|
||||||
$this->skipround = false;
|
$this->skipround = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user