
//Set icon item
setIcon(<ancientwarfare:research_book>)

//Set title String
setTitle("ANCIENT SCIENCE")

//Set description String
setDescription("Using research book, you will be able to discover more ways of generating power, as well as creating NPC's to perform various tasks for the cost of various resources.")

//Add a parent advancement. The syntax is "modid:folder/path/to/the/advancement/then/filename"
addParent("triumph:islandparadisepart2/basicwindmill")

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

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

drawDirectLines(true)

//Set the position
setPos(-72,26)

//Rewards
setRewardExperience(4)