better drop, added new setting from nc0.10

This commit is contained in:
GameHerobrine 2023-12-16 10:11:48 +03:00
parent e8528755ab
commit 7eec621f90
7 changed files with 63 additions and 65 deletions

View file

@ -138,7 +138,8 @@ class ServerAPI{
"enable-rcon" => false,
"rcon.password" => substr(base64_encode(Utils::getRandomBytes(20, false)), 3, 10),
"auto-save" => true,
"chunk-send-delay-ticks" => 5,
"chunk-send-delay-ticks" => PocketMinecraftServer::$chukSendDelay,
"chunk-loading-radius" => PocketMinecraftServer::$chunkLoadingRadius,
]);
Biome::init();
$this->parseProperties();
@ -154,6 +155,12 @@ class ServerAPI{
MobSpawner::$spawnAnimals = $this->getProperty("spawn-animals");
MobSpawner::$spawnMobs = $this->getProperty("spawn-mobs");
PocketMinecraftServer::$chukSendDelay = $this->getProperty("chunk-send-delay-ticks");
PocketMinecraftServer::$chunkLoadingRadius = $this->getProperty("chunk-loading-radius");
if(PocketMinecraftServer::$chunkLoadingRadius < 4){
ConsoleAPI::warn("Players may not be able to join if chunk loading radius is less than 4!");
}
if($this->getProperty("upnp-forwarding") == true){
console("[INFO] [UPnP] Trying to port forward...");
UPnP_PortForward($this->getProperty("server-port"));