1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

[ERROR] player teleport

Discussion in 'Development' started by Anonymous, Aug 14, 2017.

  1. Anonymous

    Anonymous Creeper

    Messages:
    1
    GitHub:
    AnonymousDev01
    PHP:
    $sender->getPlayer()->teleport($this->getServer()->getLevelByName("example")->getSafeSpawn());
    no working :/
    help me
     
  2. RoyalMCPE

    RoyalMCPE Slime

    Messages:
    87
    PHP:
    $sender->teleport Location::fromObject $this->getServer ()->getLevelByName("world")->getSpawnLocation (), $this->getServer ()->getLevelByName("world")) )
     
  3. SOFe

    SOFe Administrator Staff Member PMMP Team Poggit Admin

    Messages:
    1,968
    GitHub:
    sof3
    What is wrong with passing the getSpawnLocation() directly?
     
    Muqsit and jasonwynn10 like this.
  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.