Advertisement
TungstenVn

Untitled

Aug 21st, 2019
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.37 KB | None | 0 0
  1. public function onRespawn(PlayerRespawnEvent $e){
  2.         $p = $e->getPlayer();$n = $p->getName();       
  3.         if(null != $this->getConfig()->getNested("JailedPeoples.$n")){
  4.            $pos = $this->getConfig()->getNested("JailPosition")[0];              
  5.            $e->setRespawnPosition(new Position($pos["x"], $pos["y"], $pos["z"], $this->getServer()->getLevelByName($pos["level"])));
  6.         }
  7.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement