⚒Dynamic Item Modifiers - Athlaeos/ValhallaMMO GitHub Wiki
Dynamic item modifiers are powerful item editing functions that are able to edit an item's properties based on a player's own stats. They're used everywhere in the plugin and are responsible for making item scale with a player's skill and adding custom properties to items.
Dynamic item modifiers may also be executed in a specific order, and can also be used to apply specific item conditions to recipes to limit which items may be used during crafting.
Other plugins may register their own Dynamic Item Modifiers, so some may be present that aren't in this list
Modifiers may be applied on individual held items using /val modify <modifier> <args> <player>
ID | Description | GUI Icon | GUI Category |
---|---|---|---|
mining_speed |
Sets the Mining Power of the item. For reference: wooden tools = 2 stone tools = 4 iron tools = 6 diamond tools = 8 netherite tools = 9 golden tools = 12
|
Diamond Pickaxe | Custom Attributes |
mining_exceptions_add |
Sets the Mining Power of the item towards specific blocks | Wooden Pickaxe | Custom Attributes |
mining_hardness_translation_add |
Makes the item mine one type of block as if it was made out of another type of block | Golden Pickaxe | Custom Attributes |
loot_table |
Adds a loot table to the item. - If the item is a container, the loot table will populate the container when placed and opened. - If the item is a block, the loot table will drop when the block is placed and broken. - If the item is just a regular item, it will be rewarded to the player when right-clicked. In this case an additional property may be added in which the player may choose which loot drops they want |
Chest | Miscellaneous Item Modifiers |
dummy_helmet |
Marks the item as a dummy helmet. When placed on an armor stand, it will be turned into a DPS testing dummy | Hay Bale | Miscellaneous Item Modifiers |
cost_money |
Makes the recipe in which it is used require and consume an amount of money to craft. Requires Vault installed | Golden Nugget | Crafting Conditionals |
cost_experience |
Makes the recipe in which it is used require and consume an amount of experience orbs to craft | Bottle 'o' Experience | Crafting Conditionals |
counter_compare_item |
Compares the counter value tag on the item to the counter limit tag on the item. Cancels the recipe if the counter value exceeds counter limit . If the item does not have this tag, it defaults to 0
|
Clock | Crafting Conditionals |
counter_compare_number |
Compares the counter value tag on the item to the given number. Cancels the recipe if the counter value exceeds the given number |
Clock | Crafting Conditionals |
counter_compare_player |
Compares the counter value tag on the item to the player's counter limit stat. Cancels the recipe if the counter value exceeds that of the player's stat |
Clock | Crafting Conditionals |
counter_increment |
Increases or decreases the counter value tag on the item, or adds it if it does not exist |
Clock | Crafting Conditionals |
counter_set_item_limit |
Sets the counter limit tag on the item |
Clock | Crafting Conditionals |
smithing_tags_add |
Adds the given smithing tags to the item. Smithing tags may be used for condition checks or to add lore flavor text to the item. Tags can have a level assigned, and if an item already has one of the given tags, its level is added to the given level | Paper | Crafting Conditionals |
smithing_tags_require |
Requires the item to have all or some of the given tags, otherwise the recipe is cancelled | Paper | Crafting Conditionals |
smithing_tags_forbid |
Requires the item to not have all or any of the given tags, otherwise the recipe is cancelled | Paper | Crafting Conditionals |
smithing_tags_remove |
Removes the given smithing tags from the item | Paper | Crafting Conditionals |
smithing_tags_clear |
Removes all smithing tags from the item | Paper | Crafting Conditionals |
enchant_randomly |
Randomly enchants an item given a level | Enchantment Table | Miscellaneous Enchantment Properties |
enchantments_clear |
Clears all enchantments from the item | Grindstone | Miscellaneous Enchantment Properties |
enchant_add_<enchantment> |
Enchants an item with the given enchantment with a given level, potentially scaling with the player's Enchanting skill | Depends per enchantment | Enchantments |
amount_add |
Increases or decreases the item's amount | Stick | Miscellaneous Item Modifiers |
amount_randomized |
Randomizes the item's amount | Stick | Miscellaneous Item Modifiers |
amount_scale |
Scales the item's amount with the player's Smithing skill | Iron Ingot | Miscellaneous Item Modifiers |
amount_set |
Sets the item's amount | Stick | Miscellaneous Item Modifiers |
color_decimal |
Sets the color of the item according to a decimal value. Only works on colorable items like leather armor or potions | Potion |
Miscellaneous Item Modifiers , Miscellaneous Potion Properties
|
color_rgb |
Sets the color of the item according to RGB values. Only works on colorable items like leather armor or potions | Potion |
Miscellaneous Item Modifiers , Miscellaneous Potion Properties
|
custom_model_data |
Sets the item's custom model data | Painting | Miscellaneous Item Modifiers |
custom_id |
Sets a custom id tag to the item, can be used with ingredient choices to require a very specific ingredient |
Name Tag | Miscellaneous Item Modifiers |
rename |
Renames an item. Within the GUI this can only be configured by using another renamed item to copy its name over | Name Tag | Miscellaneous Item Modifiers |
sweeping_removal |
Nullifies all sweeping damage the item can do. Does not remove the sweeping effects, though, I don't think I can do that | Diamond Sword | Miscellaneous Item Modifiers |
durability_randomize |
Randomly damages the item's durability | Wooden Pickaxe | Miscellaneous Item Modifiers |
repair_number |
Repairs the item by a set amount | Anvil | Miscellaneous Item Modifiers |
repair_scale |
Repairs the item by a given fraction | Nether Star | Miscellaneous Item Modifiers |
durability_scale |
Scales the item's max durability with one of the player's skills | Diamond | Custom Attributes |
durability_max_set |
Sets the item's default max durability | Diamond | Miscellaneous Item Modifiers |
equipment_type |
Sets the item's tagged equipment type, which overrides their hardcoded default value | Iron Pickaxe | Miscellaneous Item Modifiers |
flag_<flag> |
Adds the given item flag to the item, see Flags. <flag> should be the flag IN LOWER CASE <<not like this | See Flags for icon | Item Flags |
replace |
Replaces the item with another | Emerald | Miscellaneous Item Modifiers |
replace_keep_amount |
Replaces the item with another, but keeps the amount of the previous item | Lapis Lazuli | Miscellaneous Item Modifiers |
material |
Changes the item's base type only | Slime Ball | Miscellaneous Item Modifiers |
unbreakable |
Makes the item unbreakable | Diamond | Miscellaneous Item Modifiers |
weight_class |
Changes the weight class of the item, overriding its hardcoded default value. Affects the light/heavy weapons/armor skills | Anvil | Miscellaneous Item Modifiers |
replace_by_custom |
Replaces the item with one of the registered items in /val items
|
Enderchest | Miscellaneous Item Modifiers |
signature |
Adds the player's signature to the item's lore | Written Book | Miscellaneous Item Modifiers |
smithing_neutral_quality_set |
Sets the item's neutral smithing quality. See Smithing for more details | Nether Star | Miscellaneous Item Modifiers |
smithing_quality_add |
Adds smithing quality to the item, or combines it with previous quality values if present | Nether Star | Miscellaneous Item Modifiers |
smithing_quality_multiply |
Multiplies the existing smithing quality value of the item | Nether Star | Miscellaneous Item Modifiers |
smithing_quality_randomize |
Randomizes the existing smithing quality value to a given range off the existing value | Stick | Miscellaneous Item Modifiers |
smithing_quality_scale |
Applies a smithing quality value to the item scaling with the player's smithing skill | Nether Star | Miscellaneous Item Modifiers |
smithing_quality_set |
Sets the item's smithing quality | Nether Star | Miscellaneous Item Modifiers |
tool_id |
Sets the item's tool ID, which can be used to have recipes require the presence or usage of that tool to craft | Iron Hoe | Miscellaneous Item Modifiers |
transform_netherite |
Changes the item's material to be that of netherite, and resets its default stats accordingly | Netherite Chestplate | Miscellaneous Item Modifiers |
transform_diamond |
Changes the item's material to be that of diamond, and resets its default stats accordingly | Diamond Chestplate | Miscellaneous Item Modifiers |
transform_iron |
Changes the item's material to be that of iron, and resets its default stats accordingly | Iron Chestplate | Miscellaneous Item Modifiers |
transform_gold |
Changes the item's material to be that of gold, and resets its default stats accordingly | Golden Chestplate | Miscellaneous Item Modifiers |
transform_chainmail |
Changes the item's material to be that of chainmail, and resets its default stats accordingly | Chainmail Chestplate | Miscellaneous Item Modifiers |
transform_leather |
Changes the item's material to be that of leather, and resets its default stats accordingly | Leather Tunic | Miscellaneous Item Modifiers |
requirement_add_<skill> |
Adds a skill level requirement to the item. If the level requirement is not met, the item's stats will be greatly diminished | Miscellaneous Item Modifiers |
|
arrow_behavior_antigrav |
When applied on arrows, makes them antigravity | Feather | Custom Attributes |
arrow_behavior_dragonball |
When applied on arrows, turns them into a dragon fireball when shot | Dragon's Breath | Custom Attributes |
arrow_behavior_explosive |
When applied on arrows, makes them explode on hit | TNT | Custom Attributes |
arrow_behavior_very_explosive |
When applied on arrows, makes them explode several times on hit | TNT Minecart | Custom Attributes |
arrow_behavior_immunityvoid |
When applied on arrows, makes them remove immunity frames on hit | Wither Skeleton Skull | Custom Attributes |
arrow_behavior_incendiary |
When applied on arrows, makes them light an area on fire on hit | Flint and Steel | Custom Attributes |
arrow_behavior_largefireball |
When applied on arrows, turns them into a large fireball when shot | Fire Charge | Custom Attributes |
arrow_behavior_lightning |
When applied on arrows, makes them spawn lightning on hit | Ice | Custom Attributes |
arrow_behavior_smallfireball |
When applied on arrows, turns them into a small fireball when shot | Fire Charge | Custom Attributes |
arrow_behavior_teleportation |
When applied on arrows, makes them teleport the shooter to the hit location | Ender Pearl | Custom Attributes |
alchemy_tags_add |
Adds the given alchemy tags to the item. Alchemy tags may be used for condition checks or to add lore flavor text to the item | Paper | Potion Conditionals |
alchemy_tags_require |
Requires the item to have all or some of the given tags, otherwise the recipe is cancelled | Paper | Potion Conditionals |
alchemy_tags_forbid |
Requires the item to not have all or any of the given tags, otherwise the recipe is cancelled | Paper | Potion Conditionals |
alchemy_tags_remove |
Removes the given alchemy tags from the item | Paper | Potion Conditionals |
alchemy_tags_clear |
Removes all alchemy tags from the item | Paper | Potion Conditionals |
potion_type_forbid_<type> |
Forbids a specific potion type from being used. Valid types are thick , awkward , water , mundane
|
Potion | Potion Conditionals |
potion_type_require_<type> |
Requires a specific potion type to be used. Valid types are thick , awkward , water , mundane
|
Potion | Potion Conditionals |
potion_type_set |
Sets the potion type of the potion | ||
transmutation_potion |
Converts the potion to Draught of Midas (See Alchemy) | Gold Block | Miscellaneous Potion Properties |
potion_amplifier_scale |
Scales the amplifier(s) of the potion's potion effects according to player skill | Glowstone Dust | Miscellaneous Potion Properties |
potion_duration_scale |
Scales the duration(s) of the potion's potion effects according to player skill | Redstone Dust | Miscellaneous Potion Properties |
potion_effect_convert |
Converts the given potion effects found on the item into another potion effect | Fermented Spider Eye | Miscellaneous Potion Properties |
alchemy_quality_add |
Adds alchemy quality to the item, or combines it with previous quality values if present | Nether Star | Miscellaneous Potion Properties |
alchemy_quality_multiply |
Multiplies the existing alchemy quality value of the item | Nether Star | Miscellaneous Potion Properties |
alchemy_quality_randomize |
Randomizes the existing alchemy quality value to a given range off the existing value | Stick | Miscellaneous Potion Properties |
alchemy_quality_scale |
Applies a alchemy quality value to the item scaling with the player's alchemy skill | Nether Star | Miscellaneous Potion Properties |
alchemy_quality_set |
Sets the item's alchemy quality | Nether Star | Miscellaneous Potion Properties |
chocolate_milk_from_milk |
Converts milk to chocolate milk | Cocoa Beans | Miscellaneous Potion Properties |
reward_item |
Rewards the player with an item | Chest | Player Rewards |
reward_money |
Rewards the player with an amount of money | Gold Nugget | Player Rewards |
reward_vanilla_experience |
Rewards the player with an amount of experience orbs | Bottle 'o' Experience | Player Rewards |
reward_<skill>_experience |
Rewards the player with an amount of skill experience. <skill> should be the name of the skill IN LOWER CASE <<not like this | Player Rewards |
|
food_nullify_effects |
When applied to food, nullifies any potion effect it would normally give (e.g. Golden Apples, Rotten Flesh) | Milk Bucket | Food Properties |
food_type |
Changes the food class of the item, overriding its hardcoded value. See Foods | Paper | Food Properties |
food_value |
Changes how many hunger points eating this food will restore | Steak | Food Properties |
food_saturation |
Changes how many saturation points eating this food will restore | Golden Carrot | Food Properties |
bait_power |
Adds a bait power tag to the item. When fishing this bait is consumed, and grants that catch fishing luck equal to the amount of bait power the item had (to be expanded upon in the future) |
Fishing Rod | Miscellaneous Item Modifiers |
armor_set |
Sets an armor set tag to the item. Armor sets are defined in /val armorsets . When wearing a full set of armor with matching armor set tags the player receives stat buffs according to what's defined with the armor set |
Diamond Chestplate | Miscellaneous Item Modifiers |
custom_durability_set |
Sets the custom max durability of the item (I don't think this needs to exist because a duplicate exists but here we are lol) | Diamond | Custom Attributes |
custom_durability_remove |
Removes any custom durability from the item | Coal | Custom Attributes |
Each attribute adds the following modifiers. See Attributes for a list
<attribute> should be the attribute IN LOWER CASE <<not like this
Each attribute also has its own icon associated, also listed on that link.
ID | Description |
---|---|
attribute_add_<attribute> |
Adds the given attribute as default stat to the item. |
attribute_remove_<attribute> |
Removes the given attribute from the item |
attribute_scale_<attribute> |
Scales the given attribute according to one of the player's skills. Default value remains unchanged, only the actualized stat changes |
Each potion effect adds the following modifiers. See Potion Effects for a list
<effect> should be the potion effect IN LOWER CASE <<not like this
Each potion effect also has its own icon associated, also listed on that link.
ID | Description |
---|---|
potion_effect_add_<effect> |
Adds the given potion effect as default effect to the item |
permanent_effect_add_<effect> |
Permanent potion effects are effects that are repeatedly applied on the player, making them virtually permanent as long as the player possesses the item. Only registered for vanilla potion effects, as most custom potion effects have an attribute stat doing the same thing |