distance and stuntsscore not available in CP-Callback of the new game
This commit is contained in:
parent
44d8fd1db2
commit
2f57ee3d6c
@ -39,14 +39,14 @@ class OnWayPointEventStructure extends BasePlayerTimeStructure {
|
|||||||
|
|
||||||
$this->raceTime = (int) $this->getPlainJsonObject()->racetime;
|
$this->raceTime = (int) $this->getPlainJsonObject()->racetime;
|
||||||
$this->lapTime = (int) $this->getPlainJsonObject()->laptime;
|
$this->lapTime = (int) $this->getPlainJsonObject()->laptime;
|
||||||
$this->stuntsScore = $this->getPlainJsonObject()->stuntsscore;
|
$this->stuntsScore = isset($this->getPlainJsonObject()->stuntsscore) ? $this->getPlainJsonObject()->stuntsscore : null;
|
||||||
$this->checkPointInRace = (int) $this->getPlainJsonObject()->checkpointinrace;
|
$this->checkPointInRace = (int) $this->getPlainJsonObject()->checkpointinrace;
|
||||||
$this->checkPointInLap = (int) $this->getPlainJsonObject()->checkpointinlap;
|
$this->checkPointInLap = (int) $this->getPlainJsonObject()->checkpointinlap;
|
||||||
$this->isEndRace = Formatter::parseBoolean($this->getPlainJsonObject()->isendrace);
|
$this->isEndRace = Formatter::parseBoolean($this->getPlainJsonObject()->isendrace);
|
||||||
$this->isEndLap = Formatter::parseBoolean($this->getPlainJsonObject()->isendlap);
|
$this->isEndLap = Formatter::parseBoolean($this->getPlainJsonObject()->isendlap);
|
||||||
$this->blockId = $this->getPlainJsonObject()->blockid;
|
$this->blockId = $this->getPlainJsonObject()->blockid;
|
||||||
$this->speed = $this->getPlainJsonObject()->speed;
|
$this->speed = $this->getPlainJsonObject()->speed;
|
||||||
$this->distance = $this->getPlainJsonObject()->distance;
|
$this->distance = isset($this->getPlainJsonObject()->distance) ? $this->getPlainJsonObject()->distance : null;
|
||||||
|
|
||||||
if ($this->checkPointInRace > 0) {
|
if ($this->checkPointInRace > 0) {
|
||||||
$currentMap = $this->maniaControl->getMapManager()->getCurrentMap();
|
$currentMap = $this->maniaControl->getMapManager()->getCurrentMap();
|
||||||
|
Loading…
Reference in New Issue
Block a user