Created
November 9, 2013 19:06
-
-
Save w1lla/7388657 to your computer and use it in GitHub Desktop.
log file ESWC ShootMania
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace ManiaLivePlugins\Shootmania\Elite\Classes; | |
class Log { | |
private $serverLogin; | |
function __construct($serverLogin) { | |
$this->serverLogin = $serverLogin; | |
$this->config = Config::getInstance(); | |
} | |
public function Normal($message) { | |
if ($this->config->Normal == true) | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Normal_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Normal_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
else | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Normal_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Normal_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
} | |
public function Console($message) { | |
if ($this->config->Console == true) | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Console_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Console_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
else | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Console_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Console_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
} | |
public function Debug($message) { | |
if ($this->config->Debug == true) | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Debug_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Debug_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
else | |
{ | |
try | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Debug_Log-'" . $this->serverLogin . "'"); | |
} | |
catch(\Exception $e) | |
{ | |
\ManiaLive\Utilities\Logger::log($message, true, "ElitePlugin_Debug_Log-'" . $this->serverLogin . "'"); | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment