Examples of BlockFace


Examples of org.bukkit.block.BlockFace

    if (playerLocation.getYaw() >= 0) {
      yaw = (int) (playerLocation.getYaw() % 360);
    } else {
      yaw = (int) (360 + (playerLocation.getYaw() % 360));
    }
    BlockFace facing = null;
    BlockFace opposite = null;
    if ((yaw >= 0 && yaw < 45) || (yaw >= 315 && yaw <= 360)) {
      facing = Direction.WEST();
      opposite = Direction.EAST();
    } else if (yaw >= 45 && yaw < 135) {
      facing = Direction.NORTH();
View Full Code Here

Examples of org.bukkit.block.BlockFace

        yaw = 270;
      }
      this.warzone.setTeleport(new Location(this.volume.getWorld(), this.zoneTeleportBlock.getX(), this.zoneTeleportBlock.getY(), this.zoneTeleportBlock.getZ(), yaw, 0));

      // set to air the minimum path
      BlockFace front = this.wall;
      BlockFace leftSide = null; // looking at the zone
      BlockFace rightSide = null;
     
      if (this.wall == Direction.NORTH()) {
        leftSide = Direction.EAST();
        rightSide = Direction.WEST();
      } else if (this.wall == Direction.EAST()) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

      War.war.log("Failed to initalize zone lobby for zone " + this.warzone.getName(), java.util.logging.Level.WARNING);
    }
  }

  private void setGatePositions(Block lobbyMiddleWallBlock) {
    BlockFace leftSide = null; // look at the zone
    BlockFace rightSide = null;
    if (this.wall == Direction.NORTH()) {
      leftSide = Direction.EAST();
      rightSide = Direction.WEST();
    } else if (this.wall == Direction.EAST()) {
      leftSide = Direction.SOUTH();
View Full Code Here

Examples of org.bukkit.block.BlockFace

    this.warHubLinkGate = lobbyMiddleWallBlock.getRelative(this.wall, 9).getLocation();
  }

  private void placeTeamGate(Block block, TeamKind teamKind) {
    if (block != null) {
      BlockFace front = this.wall;
      BlockFace leftSide = null; // looking at the zone
      BlockFace rightSide = null;
     
      if (this.wall == Direction.NORTH()) {
        leftSide = Direction.EAST();
        rightSide = Direction.WEST();
      } else if (this.wall == Direction.EAST()) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

    }
  }

  private void placeWarhubLinkGate(Block block, ItemStack frame) {
    if (block != null) {
      BlockFace front = null;
      BlockFace leftSide = null; // looking at the zone
      BlockFace rightSide = null;
     
      // warhub link is opposite direction as zone wall
      if (this.wall == Direction.NORTH()) {
        front = Direction.SOUTH();
      } else if (this.wall == Direction.EAST()) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

      if (!this.args[0].equals("north") && !this.args[0].equals("n") && !this.args[0].equals("east") && !this.args[0].equals("e") && !this.args[0].equals("south") && !this.args[0].equals("s") && !this.args[0].equals("west") && !this.args[0].equals("w")) {
        return false;
      }
      ZoneLobby lobby = zone.getLobby();

      BlockFace wall = Direction.WEST();
      String wallStr = "";
      if (this.args[0].equals("north") || this.args[0].equals("n")) {
        wall = Direction.NORTH();
        wallStr = "north";
      } else if (this.args[0].equals("east") || this.args[0].equals("e")) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

      yaw = (int) (this.location.getYaw() % 360);
    } else {
      yaw = (int) (360 + (this.location.getYaw() % 360));
    }

    BlockFace facing = null;
    if ((yaw >= 0 && yaw < 45) || (yaw >= 315 && yaw <= 360)) {
      facing = Direction.WEST();
    } else if (yaw >= 45 && yaw < 135) {
      facing = Direction.NORTH();
    } else if (yaw >= 135 && yaw < 225) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

      int hubWidth = noOfWarzones * 4 + 2;
      int halfHubWidth = hubWidth / 2;
      int hubDepth = 6;
      int hubHeigth = 4;

      BlockFace left;
      BlockFace right;
      BlockFace front = this.getOrientation();
      BlockFace back;
      if (this.getOrientation() == Direction.SOUTH()) {
        left = Direction.EAST();
        right = Direction.WEST();
        back = Direction.NORTH();
      } else if (this.getOrientation() == Direction.NORTH()) {
View Full Code Here

Examples of org.bukkit.block.BlockFace

   *
   * @param Warzone
   *                zone
   */
  public void resetZoneSign(Warzone zone) {
    BlockFace left;
    BlockFace back;
    if (this.getOrientation() == Direction.SOUTH()) {
      left = Direction.EAST();
      back = Direction.NORTH();
    } else if (this.getOrientation() == Direction.NORTH()) {
      left = Direction.WEST();
View Full Code Here

Examples of org.bukkit.block.BlockFace

    blockState.update(true);
  }

  private void placeAutoAssignGate() {
    if (this.autoAssignGate != null) {
      BlockFace front = this.wall;
      BlockFace leftSide = null; // lookingat the zone
      BlockFace rightSide = null;
     
      if (this.wall == Direction.NORTH()) {
        leftSide = Direction.EAST();
        rightSide = Direction.WEST();
      } else if (this.wall == Direction.EAST()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.