Removing some useless left from before.

This commit is contained in:
Adsooi 2017-10-31 18:22:11 +01:00 committed by GitHub
parent b7367eb4fd
commit dd4c3d95e8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,7 +53,6 @@ class Main extends PluginBase implements Listener{
echo str_repeat("\010", $downRP ? strlen(TextFormat::toANSI("§f[Spooky] ⚪ Downloading resource pack...")) : 0) . TextFormat::toANSI("§f[Spooky] ⚪ Applying resource pack... "); // Replacing latest message
$pack = new ZippedResourcePack($this->getDataFolder() . "Spooky.mcpack");
$r = new \ReflectionClass("pocketmine\\resourcepacks\\ResourcePackManager");
if($pack instanceof \pocketmine\resourcepacks\ResourcePack){
// Reflection because devs thought it was a great idea to not let plugins manage resource packs :/
$resourcePacks = $r->getProperty("resourcePacks");
$resourcePacks->setAccessible(true);
@ -69,7 +68,6 @@ class Main extends PluginBase implements Listener{
$forceResources = $r->getProperty("serverForceResources");
$forceResources->setAccessible(true);
$forceResources->setValue($this->getServer()->getResourceManager(), true);
}
echo str_repeat("\010", strlen("⚪ Applying resource pack... ")) . TextFormat::toANSI("§a✔ Done! Spooky enabled! \n");
}