mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-07 04:17:07 +00:00
Added temporal workaround for pthreads version check
This commit is contained in:
parent
1617b2509e
commit
bb4c54106a
@ -1510,6 +1510,9 @@ class Server{
|
|||||||
$this->logger->info("This server is running " . $this->getName() . " version " . ($version->isDev() ? TextFormat::YELLOW : "") . $version->get(false) . TextFormat::RESET . " \"" . $this->getCodename() . "\" (API " . $this->getApiVersion() . ")", true, true, 0);
|
$this->logger->info("This server is running " . $this->getName() . " version " . ($version->isDev() ? TextFormat::YELLOW : "") . $version->get(false) . TextFormat::RESET . " \"" . $this->getCodename() . "\" (API " . $this->getApiVersion() . ")", true, true, 0);
|
||||||
$this->logger->info($this->getName() . " is distributed under the LGPL License", true, true, 0);
|
$this->logger->info($this->getName() . " is distributed under the LGPL License", true, true, 0);
|
||||||
|
|
||||||
|
PluginManager::$pluginParentTimer = new TimingsHandler("** Plugins");
|
||||||
|
Timings::init();
|
||||||
|
|
||||||
$this->consoleSender = new ConsoleCommandSender();
|
$this->consoleSender = new ConsoleCommandSender();
|
||||||
$this->commandMap = new SimpleCommandMap($this);
|
$this->commandMap = new SimpleCommandMap($this);
|
||||||
|
|
||||||
@ -1518,9 +1521,6 @@ class Server{
|
|||||||
Item::init();
|
Item::init();
|
||||||
$this->craftingManager = new CraftingManager();
|
$this->craftingManager = new CraftingManager();
|
||||||
|
|
||||||
PluginManager::$pluginParentTimer = new TimingsHandler("** Plugins");
|
|
||||||
Timings::init();
|
|
||||||
|
|
||||||
$this->pluginManager = new PluginManager($this, $this->commandMap);
|
$this->pluginManager = new PluginManager($this, $this->commandMap);
|
||||||
$this->pluginManager->subscribeToPermission(Server::BROADCAST_CHANNEL_ADMINISTRATIVE, $this->consoleSender);
|
$this->pluginManager->subscribeToPermission(Server::BROADCAST_CHANNEL_ADMINISTRATIVE, $this->consoleSender);
|
||||||
$this->pluginManager->setUseTimings($this->getProperty("settings.enable-profiling", false));
|
$this->pluginManager->setUseTimings($this->getProperty("settings.enable-profiling", false));
|
||||||
@ -1546,6 +1546,13 @@ class Server{
|
|||||||
Generator::addGenerator("pocketmine\\level\\generator\\Normal", "normal");
|
Generator::addGenerator("pocketmine\\level\\generator\\Normal", "normal");
|
||||||
Generator::addGenerator("pocketmine\\level\\generator\\Normal", "default");
|
Generator::addGenerator("pocketmine\\level\\generator\\Normal", "default");
|
||||||
|
|
||||||
|
//Temporal workaround, pthreads static property nullification test
|
||||||
|
if(PluginManager::$pluginParentTimer === null){
|
||||||
|
$this->getLogger()->emergency("You are using an invalid pthreads version. Please update your binaries.");
|
||||||
|
kill(getmypid());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
foreach($this->getProperty("worlds", []) as $name => $worldSetting){
|
foreach($this->getProperty("worlds", []) as $name => $worldSetting){
|
||||||
if($this->loadLevel($name) === false){
|
if($this->loadLevel($name) === false){
|
||||||
$seed = $this->getProperty("worlds.$name.seed", time());
|
$seed = $this->getProperty("worlds.$name.seed", time());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user