small fix
This commit is contained in:
parent
3773882cee
commit
8bce1ea949
@ -271,8 +271,10 @@ class StatisticCollector implements CallbackListener {
|
|||||||
$victim = $this->maniaControl->playerManager->getPlayer($callback[1][1][1]);
|
$victim = $this->maniaControl->playerManager->getPlayer($callback[1][1][1]);
|
||||||
if (isset($callback[1][1][0])) {
|
if (isset($callback[1][1][0])) {
|
||||||
$shooter = $this->maniaControl->playerManager->getPlayer($callback[1][1][0]);
|
$shooter = $this->maniaControl->playerManager->getPlayer($callback[1][1][0]);
|
||||||
|
if ($shooter != null) {
|
||||||
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_KILL, $shooter);
|
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_KILL, $shooter);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_DEATH, $victim);
|
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_DEATH, $victim);
|
||||||
break;
|
break;
|
||||||
case 'LibXmlRpc_OnPlayerRequestRespawn':
|
case 'LibXmlRpc_OnPlayerRequestRespawn':
|
||||||
@ -308,6 +310,9 @@ class StatisticCollector implements CallbackListener {
|
|||||||
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_DEATH, $victim);
|
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_DEATH, $victim);
|
||||||
if (isset($paramsObject->Event->Shooter->Login)) {
|
if (isset($paramsObject->Event->Shooter->Login)) {
|
||||||
$shooter = $this->maniaControl->playerManager->getPlayer($paramsObject->Event->Shooter->Login);
|
$shooter = $this->maniaControl->playerManager->getPlayer($paramsObject->Event->Shooter->Login);
|
||||||
|
if ($shooter != null) {
|
||||||
|
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_KILL, $shooter);
|
||||||
|
}
|
||||||
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_KILL, $shooter);
|
$this->maniaControl->statisticManager->incrementStat(self::STAT_ON_KILL, $shooter);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user