Advertisement
Guest User

Untitled

a guest
Oct 21st, 2016
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.84 KB | None | 0 0
  1. @Override
  2. public void readSpawnData(ByteBuf additionalData) {
  3. NBTTagCompound nbt = ByteBufUtils.readTag(additionalData);
  4.  
  5. if (nbt.hasKey("Owner", 10)) {
  6. this.m_profile = NBTUtil.func_152459_a(nbt.getCompoundTag("Owner"));
  7. } else if (nbt.hasKey("ExtraType", 8) && !StringUtils.isNullOrEmpty(nbt.getString("ExtraType"))) {
  8. this.m_profile = new GameProfile((UUID) null, nbt.getString("ExtraType"));
  9. this.func_152109_d();
  10. }
  11.  
  12. setProfile(this.m_profile);
  13.  
  14. NBTTagList nbttaglist1;
  15. int i;
  16.  
  17. if (nbt.hasKey("Equipment", 9)) {
  18. nbttaglist1 = nbt.getTagList("Equipment", 10);
  19. for (i = 0; i < this.equipment.length; ++i) {
  20. this.equipment[i] = ItemStack.loadItemStackFromNBT(nbttaglist1.getCompoundTagAt(i));
  21. System.out.println("*************** EQUIPMENT ****************** " + this.equipment[i]);
  22. }
  23. }
  24.  
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement