Entity Move

Discussion in 'Plugin Help' started by ByAlperenS, Jun 21, 2020.

  1. ByAlperenS

    ByAlperenS Silverfish

    Messages:
    24
    GitHub:
    ByAlperenS
    Code;


    Code:
    public function ileri(PlayerMoveEvent $e){
            $p = $e->getPlayer();
            foreach(Server::getInstance()->getLevels() as $level){
                foreach($level->getEntities() as $entity){
                    if($entity instanceof TsEntity){
                        $entity->move($p->getMotion()->getX(), $p->getMotion()->getY(), $p->getMotion()->getZ());
                    }
                }
            }
        }
    Entity don't move
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.