Examples of FallingBlock


Examples of org.bukkit.entity.FallingBlock

        double y = above.getY() - 0.99D;

        if(!new Location(BukkitUtil.toSign(getSign()).getWorld(), above.getX() + 0.5D, y, above.getZ() + 0.5D).getChunk().isLoaded())
            return;

        FallingBlock block = BukkitUtil.toSign(getSign()).getWorld().spawnFallingBlock(new Location(BukkitUtil.toSign(getSign()).getWorld(), above.getX() + 0.5D, y, above.getZ() + 0.5D), this.block.getType(), this.block.getData().getData());
        block.setVelocity(velocity);
    }
View Full Code Here

Examples of org.bukkit.entity.FallingBlock

                if (EntityUtil.isEntityInBlock(ent, trigger.getRelative(piston.getFacing()))) {
                    ent.setVelocity(ent.getVelocity().add(vel));
                }
            }
        } else {
            FallingBlock fall = trigger.getWorld().spawnFallingBlock(trigger.getRelative(piston.getFacing()).getLocation().add(vel), trigger.getRelative(piston.getFacing()).getTypeId(), trigger.getRelative(piston.getFacing()).getData());
            trigger.getRelative(piston.getFacing()).setType(Material.AIR);
            fall.setVelocity(vel);
        }
    }
View Full Code Here

Examples of org.spout.vanilla.component.entity.substance.FallingBlock

    super(type);
  }

  @Override
  public List<Message> getSpawnMessages(Entity entity, RepositionManager rm) {
    FallingBlock block = entity.get(FallingBlock.class);
    if (block != null && block.getMaterial() instanceof VanillaBlockMaterial) {
      VanillaBlockMaterial material = (VanillaBlockMaterial) block.getMaterial();
      int messageData = material.getMinecraftId() | (material.getMinecraftData(material.getData()) >> 16);
      List<Message> messages = new ArrayList<Message>();
      //TODO: Redo this as FallingBlock will remain an Entity
      //
      //      final double p = 32d;
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.