Examples of Burn


Examples of org.spout.vanilla.component.entity.misc.Burn

    // Add metadata associated with general living Entity properties
    getOwner().add(MetadataComponent.class).addMeta(new Metadata<Byte>(Metadata.TYPE_BYTE, 0) {
      @Override
      public Byte getValue() {
        byte value = 0;
        Burn burn = getOwner().get(Burn.class);
        if (burn != null) {
          value = (byte) (value | (burn.isOnFire() ? 1 : 0));
        }

        value = (byte) (value | ((isSneaking() ? 1 : 0) << 1));
        value = (byte) (value | ((isRiding() ? 1 : 0) << 2));
View Full Code Here

Examples of org.spout.vanilla.component.entity.misc.Burn

  public void fire(Player player, CommandArguments args) throws CommandException {
    final float time = args.popFloat("time");
    final boolean hurt = args.popBoolean("hurt", false);
    args.assertCompletelyParsed();

    Burn fire = player.add(Burn.class);
    fire.setOnFire(time, hurt);
  }
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.