Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- __PocketMine Plugin__
- class=p49XhaiB
- name=KitPvP
- author=SkyrexMC
- version=1.0
- apiversion=12
- */
- class p49XhaiB implements plugin{
- private $api;
- public function __construct(ServerAPI $api, $s = false){$this->api=$api;}
- public function init(){$this->api->addHandler("player.block.touch", array($this, "eventHandler"), 100);
- }
- public function eventHandler($data){switch($event)
- {
- case "player.block.touch":
- if($data["item"]->getID() === BEETROOT_SOUP){ $data["player"]->entity->heal(5);}
- }
- }
- public function __destruct()
- {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement