renamed server id to index
This commit is contained in:
		@@ -90,9 +90,9 @@ class StatisticCollector implements CallbackListener {
 | 
			
		||||
 | 
			
		||||
		//Write Shoot Data into database
 | 
			
		||||
		if($this->onShootArray[$login] > $this->maniaControl->settingManager->getSetting($this, self::SETTING_ON_SHOOT_PRESTORE)) {
 | 
			
		||||
			$serverId = $this->maniaControl->server->getServerId();
 | 
			
		||||
			$serverIndex = $this->maniaControl->server->getIndex();
 | 
			
		||||
			$player      = $this->maniaControl->playerManager->getPlayer($login);
 | 
			
		||||
			$this->maniaControl->statisticManager->insertStat(self::STAT_ON_SHOOT, $player, $serverId, $this->onShootArray[$login]);
 | 
			
		||||
			$this->maniaControl->statisticManager->insertStat(self::STAT_ON_SHOOT, $player, $serverIndex, $this->onShootArray[$login]);
 | 
			
		||||
			$this->onShootArray[$login] = 0;
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
@@ -114,8 +114,8 @@ class StatisticCollector implements CallbackListener {
 | 
			
		||||
		//Insert Data into Database, and destroy player
 | 
			
		||||
		if(isset($this->onShootArray[$player->login])) {
 | 
			
		||||
			if($this->onShootArray[$player->login] > 0) {
 | 
			
		||||
				$serverId = $this->maniaControl->server->getServerId();
 | 
			
		||||
				$this->maniaControl->statisticManager->insertStat(self::STAT_ON_SHOOT, $player, $serverId, $this->onShootArray[$player->login]);
 | 
			
		||||
				$serverIndex = $this->maniaControl->server->getIndex();
 | 
			
		||||
				$this->maniaControl->statisticManager->insertStat(self::STAT_ON_SHOOT, $player, $serverIndex, $this->onShootArray[$player->login]);
 | 
			
		||||
			}
 | 
			
		||||
			unset($this->onShootArray[$player->login]);
 | 
			
		||||
		}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user