So I tried to make my own plugin but it always gives me error and I don't know what's wrong with it. Please help me Code: <?php namespace ServerCore; use pocketmine\plugin\PluginBase; use pocketmine\command\CommandSender; use pocketmine\command\Command; use pocketmine\Player; use pocketmine\Server; use pocketmine\utils\TextFormat as c; class ServerCore extends PluginBase{ public function onEnable(){ $this->getLogger()->notice(c::BOLD.c::DARK_AQUA."(!)".c::RESET.c::DARK_PURPLE." ServerCore has been enabled"); } public function onCommand(CommandSender $sender, Command $cmd, $label, array $args){ if(strtolower($cmd->getName()) == "heal"){ if($sender->hasPermission("Mod")){ $sender->sendMessage(c::BOLD.c::DARK_AQUA."(!)",c::DARK_PURPLE." You have been healed"); $sender->setHealth(20.0); }elseif(!$sender->hasPermission("Mod")){ $sender->sendMessage(c::BOLD.c::DARK_RED."(!)".c::RESET.c::RED." You do not have permission to run this command"); } } } public function onDisable(){ $this->getLogger()->warning(c::BOLD.c::DARK_RED."(!)".c::RESET.c::RED." ServerCore has been disabled") } }
A. Post the error you're getting. It tells us what happened, what went wrong, etc. The problem here was simple enough to be solved without it, but you should always post error logs with it if you want help. "It gives me error" doesn't describe a thing. B. You're missing a semicolon. You really should use an IDE.