Skip to content

Commit

Permalink
Update Server.php
Browse files Browse the repository at this point in the history
  • Loading branch information
KnosTx authored Oct 27, 2024
1 parent 607f091 commit d817ccf
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -897,7 +897,7 @@ public function __construct(
}

$this->asyncPool = new AsyncPool($poolSize, max(-1, $this->configGroup->getPropertyInt(Yml::MEMORY_ASYNC_WORKER_HARD_LIMIT, 256)), $this->autoloader, $this->logger, $this->tickSleeper);

$netCompressionThreshold = -1;
if($this->configGroup->getPropertyInt(Yml::NETWORK_BATCH_THRESHOLD, 256) >= 0){
$netCompressionThreshold = $this->configGroup->getPropertyInt(Yml::NETWORK_BATCH_THRESHOLD, 256);
Expand Down Expand Up @@ -1017,9 +1017,6 @@ public function __construct(

$this->playerDataProvider = new DatFilePlayerDataProvider(Path::join($this->dataPath, "players"));

$this->currentWeather = WeatherType::CLEAR;
$this->setWeatherDuration();

register_shutdown_function($this->crashDump(...));

$loadErrorCount = 0;
Expand Down Expand Up @@ -1071,6 +1068,9 @@ public function __construct(
$this->console = new ConsoleReaderChildProcessDaemon($this->logger);
}

$this->currentWeather = WeatherType::CLEAR;
$this->setWeatherDuration();

$this->tickProcessor();
$this->forceShutdown();
}catch(\Throwable $e){
Expand Down

0 comments on commit d817ccf

Please sign in to comment.