-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainClass.php
More file actions
39 lines (29 loc) · 1.22 KB
/
MainClass.php
File metadata and controls
39 lines (29 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?php
namespace ExamplePlugin;
use pocketmine\command\Command;
use pocketmine\command\CommandSender;
use pocketmine\event\Listener;
use pocketmine\event\player\PlayerRespawnEvent;
use pocketmine\Player;
use pocketmine\plugin\PluginBase;
use pocketmine\Server;
use pocketmine\utils\TextFormat;
class MainClass extends PluginBase implements Listener{
public function onLoad(){
$this->getLogger()->info(TextFormat::WHITE . "I've been loaded!");
}
public function onEnable(){
$this->getServer()->getPluginManager()->registerEvents($this, $this);
$this->getServer()->getScheduler()->scheduleRepeatingTask(new BroadcastPluginTask($this), 120);
$this->getLogger()->info(TextFormat::DARK_GREEN . "I've been enabled!");
}
public function onDisable(){
$this->getLogger()->info(TextFormat::DARK_RED . "I've been disabled!");
}
public function ScoreboardStats()
$this->$Name = $players->getPlayer()->getName();
$this->$Money = $this->EconomyS->mymoney($Name);
$this->$Death = PlayerDeathEvent->Death(Death);
$this->$Kills = PlayerKillsEvent->Kills(Kills)
$this->$players->sendTip(" §b« §7ScoreKill §b »\n §eMEMBER:§b $Name !\n §aMoney:§f $Money §e\Kills: $Kills \ Death: $Death ");
}