Code: public function onMove(PlayerMoveEvent $event){ $player = $event->getPlayer(); if($event->getTo()->getX() === $x){ if($event->getTo()->getY() === $y){ if($event->getTo()->getZ() === $z){ $player->addEffect(new EffectInstance(Effect::getEffect(2), 10*20, 2, false)); $player->addEffect(new EffectInstance(Effect::getEffect(15), 10*20, 2, false)); } } } } can use PlayerMoveEvent so that when the player goes to a position addEffect() to the player