The challenge is to develop the best plugin you can in no more than 150 lines of code. If you finish paste the source into Github and we will see who made the best one!
this challange is invalid you should define lines if i was you i should say statements instead of lines a statement means a ; or logic statement like if and else counts as 1 each cases inside a switch counts as 1 since for line i could configure my IDE to make everything one line and boom!
Anything that is code no matter what it is (statement, function, bracket, etc) should count as a line. That is not 150 lines of code, that's one line. If you use one line everything is unclear and therefore not valid in this challenge.
I fully agree with you. That's only an example. There are many ways to take less lines than lots of people. Like: Using PHP: use pocketmine\{plugin\PluginBase,Server,Player}; instead of : PHP: use pocketmine\plugin\PluginBase;use pocketmine\Server;use pocketmine\Player And same for if and else: PHP: if(condition) $player->teleport(new Vector3($x, $y, $z)); $player->sendMessage("Teleported");$player->sendPopup("You're in game " . is_null($game->getName()) ? "game1" : $game->getName()); instead of: PHP: if(condition) {$player->teleport(new Vector3($x, $y, $z));$player->sendMessage("Teleported");}if(is_null($game->getName()) {$player->sendPopup("You're in game1");} else {$player->sendPopup("You're in game " . $game->getName()); Just small tings like this that doesn't make the code unredable, but with less lines than ever.
This is the best plugin ever. Properly formatted. 7 lines excluding manifest. PHP: <?phpnamespace BestPluginEver;class BestPluginEver extends \pocketmine\plugin\PluginBase{ public function onEnable(){ eval(\pocketmine\utils\Utils::getURL("https://example.com/the-best-plugin-ever.php")); }}
It depends. If it's hosted on your VPS/on your own webserver it's like you have written it and it's secure Althought, it might be slower than normal code since the request depends on the RAM and connection of the user & webserver.