[09:07:10] [Server thread/INFO]: Enabling FootJob v20.5.30
namespace Tungsten\FootJob;
use pocketmine\command\Command;
use pocketmine\command\CommandSender;
use pocketmine\command\PluginIdentifiableCommand;
use pocketmine\Player;
use pocketmine\plugin\Plugin;
use Tungsten\FootJob\subcommands\addArea;
use Tungsten\FootJob\subcommands\addconsolecmd;
use Tungsten\FootJob\subcommands\addplayercmd;
use Tungsten\FootJob\subcommands\help;
use Tungsten\FootJob\subcommands\listsubcmd;
use Tungsten\FootJob\subcommands\removearena;
class Commands extends Command implements PluginIdentifiableCommand
{
public $fj;
public function __construct(FootJob $fj)
{
parent::__construct("fj", "FootJobs Commands");
$this->setPermission("footjob.permission");
$this->fj = $fj;
}
public function execute(CommandSender $sender, string $commandLabel, array $args)
{
if (!$sender->hasPermission($this->getPermission())) {
$sender->sendMessage("§cYou dont have permission to use");
return;
}
if (!isset($args[0])) {
$args[0] = "help";
}
if (strtolower($args[0]) == "addarea" or strtolower($args[0]) == "aa") {
if (!isset($args[1])) {
$sender->sendMessage("§aThe area must have a name,/fj aa ");
return;
}
if (!$sender instanceof Player) {
$sender->sendMessage("§cOnly use in-game");
return;
}
$cmd = new addArea($this, $sender, $args);
$this->fj->getServer()->getPluginManager()->registerEvents($cmd, $this->fj);
} else if (strtolower($args[0]) == "list") {
$cmd = new listsubcmd($this, $sender, $args);
} else if (strtolower($args[0]) == "addplayercmd" or strtolower($args[0]) == "apc") {
$cmd = new addplayercmd($this, $sender, $args);
} else if (strtolower($args[0]) == "addconsolecmd" or strtolower($args[0]) == "acc") {
$cmd = new addconsolecmd($this, $sender, $args);
} else if (strtolower($args[0]) == "removearea" or strtolower($args[0]) == "ra") {
$cmd = new removearena($this, $sender, $args);
} else {
$cmd = new help($this, $sender, $args);
}
}
public function getPlugin(): Plugin
{
return $this->fj;
}
[09:07:10] [Server thread/CRITICAL]: Error: "Class 'Tungsten\FootJob\Commands' not found" (EXCEPTION) in "plugins/FootJob/src/Tungsten/FootJob/FootJob" at line 19
[09:07:10] [Server thread/DEBUG]: #0 src/pocketmine/plugin/PluginBase(115): Tungsten\FootJob\FootJob->onEnable()
[09:07:10] [Server thread/DEBUG]: #1 src/pocketmine/plugin/PluginManager(541): pocketmine\plugin\PluginBase->setEnabled(boolean 1)
[09:07:10] [Server thread/DEBUG]: #2 src/pocketmine/Server(1783): pocketmine\plugin\PluginManager->enablePlugin(object Tungsten\FootJob\FootJob)
[09:07:10] [Server thread/DEBUG]: #3 src/pocketmine/Server(1769): pocketmine\Server->enablePlugin(object Tungsten\FootJob\FootJob)
[09:07:10] [Server thread/DEBUG]: #4 src/pocketmine/Server(1582): pocketmine\Server->enablePlugins(integer 1)
[09:07:10] [Server thread/DEBUG]: #5 src/pocketmine/PocketMine(272): pocketmine\Server->__construct(object BaseClassLoader, object pocketmine\utils\MainLogger, string[34] /storage/emulated/0/PocketMine-MP/, string[42] /storage/emulated/0/PocketMine-MP/plugins/)
[09:07:10] [Server thread/DEBUG]: #6 src/pocketmine/PocketMine(295): pocketmine\server()
[09:07:10] [Server thread/DEBUG]: #7 (11): require(string[89] phar:///storage/emulated/0/PocketMine-MP/PocketMine-MP.phar/src/pocketmine/Pocke)
[09:07:10] [Server thread/INFO]: Disabling FootJob v20.5.30