Package com.bergerkiller.bukkit.tc.utils

Examples of com.bergerkiller.bukkit.tc.utils.TrackMap


      max = this.getGroup().getProperties().getSpeedLimit();
    }
    return new Vector(entity.vel.x.getClamped(max), entity.vel.y.getClamped(max), entity.vel.z.getClamped(max));
  }
  public TrackMap makeTrackMap(int size) {
    return new TrackMap(this.getBlock(), this.direction, size);
  }
View Full Code Here


    }

    // Track map debugging logic
    if (DEBUG_DO_TRACKTEST) {
      // Track map test
      TrackMap map = new TrackMap(clickedBlock, FaceUtil.yawToFace(player.getLocation().getYaw() - 90, false));
      while (map.hasNext()) {
        map.next();
      }
      byte data = 0;
      for (Block block : map) {
        BlockUtil.setTypeAndRawData(block, Material.WOOL, data, false);
        data++;
View Full Code Here

  public void destroy(SignActionEvent info) {
    removeDetector(info.getBlock());
  }

  public boolean tryBuild(Block startrails, Block startsign, BlockFace direction) {
    final TrackMap map = new TrackMap(startrails, direction, TrainCarts.maxDetectorLength);
    map.next();
    //now try to find the end rails : find the other sign
    Block endsign = null;
    SignActionEvent info;
    while (map.hasNext()) {
      for (Block signblock : Util.getSignsFromRails(map.next())) {
        info = new SignActionEvent(signblock);
        if (match(info)) {
          endsign = signblock;
          //start and end found : add it
          final DetectorSignPair detector = new DetectorSignPair(startsign, endsign);
View Full Code Here

TOP

Related Classes of com.bergerkiller.bukkit.tc.utils.TrackMap

Copyright © 2018 www.massapicom. 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.