//Set icon item
setIcon("minecraft:leaves")

//Set title String
setTitle("Leaf blower")

//Set description String
setDescription("Break leaves to get sticks")

//Set the parent advancement. The syntax is "modid:folder/path/to/the/advancement/then/filename"
setParent("triumph:engineer/root")

//Adds criteria named "brokeLog" with the trigger type "triumph:player_break_block". This function returns the criteria as an object
criteria = addCriteria("brokeLeaves", "triumph:player_break_block")
criteria.setBlock("minecraft:leaves")
criteria = addCriteria("brokeLeaves2", "triumph:player_break_block")
criteria.setBlock("minecraft:leaves2")


//Sets the item reward. A second variable can be added for meta, and a third can be added for stack size
setRewardItem("minecraft:cooked_porkchop", 0, 6)

//Sets the requirements to be any. This means that if ANY of the criteria triggers is acquired, the advancement is acquired.
setRequirements("any")

setRewardExperience(100)