
//Set icon item
setIcon(<dimensionaledibles:end_cake>)

//Set title String
setTitle("Is this the End?")

//Set description String
setDescription("The Ender Cake, like the Nether cake, will transport you to the End when right clicked.")

//Add a parent advancement. The syntax is "modid:folder/path/to/the/advancement/then/filename"
addParent("triumph:end/adamainiteplate")
addParent("triumph:end/reusableendereye")
addParent("triumph:end/zaniteblock")

//Adds criteria named "hasFlint" with the trigger type "minecraft:inventory_changed". This function returns the criteria as an object
criteria = addCriteria("hasEnderCake", "minecraft:inventory_changed")

//Adds the required item for the criteria. This is the item that needs to be in the player inventory.
criteria.addItem(<dimensionaledibles:end_cake>)

drawDirectLines(true)

//Set the position
setPos(11,105)

//Rewards
setRewardExperience(4)