Advertisement
Guest User

Untitled

a guest
Aug 22nd, 2017
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. ArmorStand a = (ArmorStand) spawnEntity(p.getLocation().add(X: .5, y: 1.5, z: .5), EntityType.ARMOR_STAND);
  2. Bat b = (Bat) p.getWorld().spawnEntity(p.getLocation().add(0.5, 2, 0.5), EntityType.BAT);
  3. a.setVisbleoderso(false);
  4. a.setGrivsleoderso(false);
  5. b.setLeashHolder(p);
  6. a.setMetadata("ballon-" + p.getName(), new FixedMetadataValue(Main.plugin, true));
  7. b.setMetadata("ballon2-" + p.getName(), new FixedMetadataValue(Main.plugin, true));
  8. elist.add(b);
  9. elist.add(a);
  10. Object nmse = NBTLibary.getNmsEntity(b);
  11. b.setRemoveWhenFarAway(false);
  12. NBTLibary.setSlotsDisabled(b, true);
  13. Object tag = NBTLibary.getTag(nmse);
  14. NBTLibary.setBoolean(tag, "NoAI", true);
  15. NBTLibary.saveTagF(nmse, tag);
  16. ballons.add(p);
  17. p.closeInventory();
  18. p.updateInventory();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement