1.13 custom advancements with nbt data

Discussion in 'Programming' started by CyberDrain, Aug 5, 2018.

  1. Hey all.

    With 1.13 it is now possible to add nbt data to your icons when it comes to advancements. This should allow players to put nbt data on player heads in order to show a different texture.

    https://minecraft.gamepedia.com/Advancements (see JSON Format)

    It even says on the wiki that it allows nbt data, but I am unsure what the format of the nbt data is. I'm fairly certain the value is one string containing the needed information, but somehow I keep getting a generic error saying the advancement can't be loaded.

    Code (Text):
    "icon":{
             "item":"player_head",
             "nbt": "{SkullOwner:{Id:\"67660f38-cad9-4075-bf8e-7ff242373e53\",Properties:{textures:[{Value:\"eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTg2MjViYzk5NzEyNTZhYjNiMWRlNWU3YjMzMzhkNWRlYzI2ODNiZmVmMDMxMDc5MzQ5NWQyN2FhMzhhYTQwOCJ9fX0=\"}]}}}"
          },
    If anyone can help me out with the format of the nbt data, that'd be great ^^
     
  2. Have you tried comparing it with one generated through code (by creating the objects and then serialising them)
     
  3. I have not, I'll look into that tonight. Thanks :)