Third-Party Mod Integration/Craft Tweaker

Advent of Ascension includes support for custom CraftTweaker integration beyond the normally accessible CraftTweaker functions.

Information
Information regarding using CraftTweaker can be found on the CraftTweaker documentation site here: https://docs.blamejared.com/1.12/en/index/

CraftTweaker integration can be disabled within AoA by setting enabled to false in the CraftTweaker subcategory of the Integrations Config.

The below content assumes the user knows how CraftTweaker and its functions work.

Infusion Table
Custom Infusion Table recipes can be added and removed using the below methods:

Package:

Adding an Infusion Recipe
Arguments:
 * (String) id - The unique ID for the recipe. Needs to be unique to the recipe and not conflict with any other Infusion recipes
 * (IItemStack) output - An item stack representing the output portion of the recipe. This is the final result of the recipe when used.
 * (IItemStack) input - An item stack representing the output portion of the recipe.This represents the left-most slot in the Infusion GUI.
 * (IIngredient[]) infusionIngredients - A list of ingredients to be used in the 3x3 Infusion grid. All recipes are shapeless, and must not have more than 9 ingredients.
 * (long) infusionLevelReq - A long value defining what level in Infusion the player must be to be able to use this recipe. Defaults to 1 if omitted.
 * (int) minXp - An integer value defining the minimum amount of Infusion XP to gain when completing the recipe. A random amount of XP is given between minXp and maxXp. Defaults to 0 if omitted.
 * (int) maxXp - An integer value defining the maximum amount of Infusion XP to gain when completing the recipe. A random amount of XP is given between minXp and maxXp. Defaults to 0 if omitted.

Adding an Imbuing Recipe
Arguments:
 * (String) id - The unique ID for the recipe. Needs to be unique to the recipe and not conflict with any other Infusion recipes
 * (IItemStack) input - An item stack representing the input portion of the recipe. This represents the left-most slot in the Infusion GUI.
 * (IIngredient[]) infusionIngredients - A list of ingredients to be used in the 3x3 Infusion grid. All recipes are shapeless, and must not have more than 9 ingredients.
 * (String) enchantmentId - The ID of the enchantment to imbue into the input item. Must include the mod ID, E.G. "aoa3:sever"
 * (long) enchantmentLevel - The level of enchantment to apply when completing the imbuing recipe. Defaults to 1 if omitted.
 * (long) infusionLevelReq - A long value defining what level in Infusion the player must be to be able to use this recipe. Defaults to 1 if omitted.
 * (int) minXp - An integer value defining the minimum amount of Infusion XP to gain when completing the recipe. A random amount of XP is given between minXp and maxXp. Defaults to 0 if omitted.
 * (int) maxXp - An integer value defining the maximum amount of Infusion XP to gain when completing the recipe. A random amount of XP is given between minXp and maxXp. Defaults to 0 if omitted.

Removing an Infusion Recipe
Arguments: Arguments: Example:
 * (String) resourcePath - The ID of the recipe (as added by either AoA, or another mod via CraftTweaker or otherwise.
 * (IItemStack) outputStack - An item stack representing the output of an existing Infusion recipe. Removes all Infusion recipes registered outputting a stack that is functionally equivalent to this argument.

Removing an Imbuing Recipe
Arguments:
 * (String) enchantmentId - The ID of the enchantment to match for removing Imbuing recipes. All Imbuing recipes utilising this enchantment with the correct enchantment level will be removed.
 * (int) enchantmentLevel - The enchantment level of the Imbuing recipe to match.

Upgrade Kit Recipes
Custom Upgrade Kit recipes can be added or removed via CraftTweaker using the below methods:

Package:

Adding an Upgrade Kit Recipe
Arguments:
 * (String) id - The unique ID for the recipe. Needs to be unique to the recipe and not conflict with any other Upgrade Kit recipes
 * (IItemStack) input - An item stack representing the input portion of the recipe. This represents the left-most slot in the Divine Station GUI.
 * (IItemStack) upgradeKit - An item stack representing the upgrade kit portion of the recipe. This represents the middle-most slot in the Divine Station GUI.
 * (IItemStack) output - An item stack representing the output portion of the recipe. This is the final result of the recipe when used.

Removing an Upgrade Kit Recipe
Arguments:
 * (String) resourcePath - The ID of the recipe (as added by either AoA, or another mod via CraftTweaker or otherwise.

Arguments:
 * (IItemStack) output - An item stack representing the output of an existing Upgrade Kit recipe. Removes all Upgrade Kit recipes registered outputting a stack that is functionally equivalent to this argument.

Player Functions
AoA adds an extension to the  interface of CraftTweaker, to allow access to various player stats and resources.

This can be accessed by calling the aoa3 parameter of an IPlayer object. E.G.

This extension can then be used to interact via the following methods:

Getting a Skill Level
Arguments:
 * (String) skillName - The name of the skill to find the level for. E.G. Logging.
 * (boolean) ignoreLevelCap - Whether to get the player's current level, capped at level 100. If true, will return the player's level, including vanity levels (101-1000). Defaults to false if omitted.

Returns:
 * int - The level the player is in the given skill.

Getting a Skill's XP
Arguments:
 * (String) skillName - The name of the skill to find the xp for. E.G. Logging.

Returns:
 * float - The xp the player has in the given skill.

Giving a Player XP
Arguments:
 * (String) skillName - The name of the skill to give xp for. E.G. Logging.
 * (float) xpAmount - The amount of xp to give for the skill.

Getting a Resource Value
Arguments:
 * (String) resourceName - The name of the resource to get the value for. E.G. Creation

Returns:
 * float - The resource value the player has in the given resource.

Giving Resources
Arguments:
 * (String) resourceName - The name of the resource to get the value for. E.G. Creation
 * (float) amount - The amount of resource points to give to the player.

Getting Tribute Amount
Arguments:
 * (String) deityName - The name of the deity to get the tribute value for. E.G. Erebon

Returns:
 * int - The amount of tribute the player currently has for the given deity.

Consuming Resources
Arguments:
 * (String) resourceName - The name of the resource to consume points from. E.G. Creation
 * (int) amount - The amount of resource to consume in the given resource type.
 * (boolean) forceConsume - Consume up to the amount of resource defined, even if the player doesn't currently have enough resource points to do so (will take the player to 0 points).

Returns:
 * boolean - Whether or not the player had enough resource points to consume the defined amount. If the player is in creative, this will always return true.

Giving Tribute
Arguments:
 * (String) deityName - The name of the deity to give tribute points for. E.G. Erebon
 * (int) amount - The amount of tribute to give for the given deity.

Resetting Tribute
Resets all deity tribute to 0 for the player.

Getting Current Global XP Modifier
Gets the current skill XP modifier the player has, which affects the amount of xp gained in any skill.

Returns:
 * float - The current global xp multiplier for the player. A modifier of 2.0 means the player will be gaining xp in all skills at 2x the speed of normal.

Adding Global XP Modifiers
Arguments:
 * (float) amount - The percentage amount multiplier to add to the player's global xp modifier. E.G. Adding 0.25 gives the player 25% more skill xp globally. This resets on player death or logout.

Removing Global XP Modifiers
Arguments:
 * (float) amount - The percentage amount multiplier to remove from the player's global xp modifier. E.G. Removing 0.25 gives the player 25% less skill xp globally. This resets on player death or logout.

Adding Skill XP Modifiers
Arguments:
 * (String) skillName - The name of the skill to add a modifier for. E.G. Logging.
 * (float) amount - The percentage amount multiplier to add to the player's specific skill xp modifier. E.G. Adding 0.25 gives the player 25% more skill xp in the provided skill. This resets on player death or logout.

Removing Skill XP Modifiers
Arguments:
 * (String) skillName - The name of the skill to remove a modifier for. E.G. Logging.
 * (float) amount - The percentage amount multiplier to remove from the player's specific skill xp modifier. E.G. Removing 0.25 gives the player 25% less skill xp in the provided skill. This resets on player death or logout.

Getting Current Armour Set Type
Returns:
 * IItemStack - An item that represents the armour type for which the player is currently utilising a full set bonus.