From 7d09e1be327e39d9b7fdc3244b82b2b52999a8ae Mon Sep 17 00:00:00 2001 From: Jeroen De Meerleer Date: Fri, 27 Sep 2019 01:08:14 +0200 Subject: [PATCH] BUGFIX: Absent players were not read out properly --- src/Readers/Swar4.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Readers/Swar4.php b/src/Readers/Swar4.php index 6d5e109..c51b477 100644 --- a/src/Readers/Swar4.php +++ b/src/Readers/Swar4.php @@ -428,7 +428,6 @@ class Swar4 implements ReaderInterface if ($this->getTournament()->getBinaryData('Pairing_' . $ptn . '_opponent') != 4294967295) { $pairing->setOpponent($this->getTournament()->getPlayerById($inscriptionNos[$this->getTournament()->getBinaryData('Pairing_' . $ptn . '_opponent')])); } - //echo $ptn . ' ' . $this->getTournament()->getBinaryData('Pairing_' . $ptn . '_round') . ' ' . $pairing->getPlayer()->getName() . ' - ' . $opponent . ' ' . $this->getTournament()->getBinaryData('Pairing_' . $ptn . '_result') . PHP_EOL; switch ($this->getTournament()->getBinaryData('Pairing_' . $ptn . '_result')) { case '1000': $result = Result::lost; @@ -456,6 +455,9 @@ class Swar4 implements ReaderInterface $result = Result::none; break; } + if ($this->getTournament()->getBinaryData('Pairing_' . $ptn . '_table') == 16384) { + $result = Result::absent; + } $pairing->setResult(new Result($result)); switch ($this->getTournament()->getBinaryData('Pairing_' . $ptn . '_color')) {