Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Away from coordinates

Comments in 'Plugin Development' started by JackboyPlay, Jul 13, 2016.

  1. JackboyPlay
    Offline

    JackboyPlay Active Member

    Joined:
    Apr 25, 2015
    Posts:
    507
    Minecraft User:
    JackboyPlay
    How can I check how many blocks a player is away from the coordinate x = 4 y = 20 z = 5
  2. CraftYourBukkit
    Offline

    CraftYourBukkit Notable Member Plugin Developer

    Joined:
    Jan 20, 2015
    Posts:
    1,022
    Plugins:
    2
    Minecraft User:
    CraftYourBukkit
    PHP:
    $distance $player->distance(new Vector3($x$y$z));
    While $player is your player object and $x, $y, $z the coordinates.
    JackboyPlay likes this.

Share This Page

Advertisement