<?php
namespace sethealth;
use pocketmine\event\Listener;
use pocketmine\plugin\PluginBase;
use pocketmine\event\player\playerJoinEvent;
use pocketmine\Player;
class dbxs extends PluginBase implements Listener{
public function onEnable(){
$this->getServer()->getPluginManager()->registerEvents($this,$this);
$this->getLogger()->info("启动中");
}
public function onLoad(){
$this->getLogger()->info("加载中");
}
public function onDisable(){
$this->getLogger()->info("卸载中");
}
public function onJoin(playerJoinEvent $event){
$event->getPlayer()->setHealth(40);
}
}
?>
namespace sethealth;
use pocketmine\event\Listener;
use pocketmine\plugin\PluginBase;
use pocketmine\event\player\playerJoinEvent;
use pocketmine\Player;
class dbxs extends PluginBase implements Listener{
public function onEnable(){
$this->getServer()->getPluginManager()->registerEvents($this,$this);
$this->getLogger()->info("启动中");
}
public function onLoad(){
$this->getLogger()->info("加载中");
}
public function onDisable(){
$this->getLogger()->info("卸载中");
}
public function onJoin(playerJoinEvent $event){
$event->getPlayer()->setHealth(40);
}
}
?>