# THESE ARE USED IN A LOT OF PLACES; DO NOT CHANGE THE STRUCTURE, ONLY ADD TO THE APPROPRIATE LISTS
# -By Tobbzn, from The Way of Kings CK3 mod.

## In this file, you can:
# Add new artifacts (Also need to set the appropriate localization and modifier) 
# Add new artifact slots (May need extra customizable_localization and scripted_triggers)
# Add new artifact types (May need extra customizable_localization and scripted_triggers)
# Add new artifact rarities (May need extra customizable_localization and scripted_triggers)

## NOTE FOR MODDERS:
# To use complicated strings as arguments, you MUST call the core or custom artifact list *directly*, because strings will get resolved after being passed from one function to the next. I have not been able to find a workaround, but there might exist one if one implements arguments of the form TYPE = "$TYPE$".
# This restriction includes empty "" strings! Those are perhaps the most complicated of all!

##### How to add a brand new artifact: 
# 1. Choose a name for your artifact, henceforth referred to as "(ID)".
# ID can be an integer like 534 or a string like Supersword_420_xoxo.
# The benefit of choosing an integer between 32 and 999 is that you won't have to manually add lines to the texticons to get an icon loaded, because we already added those.
# The mod will automatically detect .dds image files with path gfx/artifacts/artifact_(ID).dds 
# 2. Add the line 
#     $APPLY$ = {ARTIFACT = $PREFIX$artifact_(ID)$SUFFIX$ A = $A$ B = $B$ }
# to one of the for_TYPE_artifacts functions in common/scripted_effects/artifacts_custom.txt
# 3. Add the effects of equipping the artifact in common/modifier/artifact_modifiers.txt
# 4. Add the localization to localization/english/artifacts_loc_l_english.yml or the equivalent if you're localizing for a different language. Inspect the examples in the existing file.
# 5. Add an icon to the gfx/artifacts folder as artifact_ID.dds
# 6. If your ID is not an integer between 32 and 999, you need to copy one of the entries of gui/artifact_icons.gui with your (ID). You can then choose whatever icon path you want.

##### How to add a new artifact slot or type(such as handheld artifacts or armor):
# Add your type or slot to the appropriate lists at the start of artifacts_custom.txt
#for_all_slots
#for_all_non_slots
#for_all_rarities
# IF SLOT TYPE: The above core and custom commands must be added to for_all_artifacts_core and for_all_artifacts_custom
# Useful functions to add to your type:
#for_TYPE_artifacts_prefix
#for_TYPE_artifacts_suffix 
#for_TYPE_artifacts_nofix <- Particularly useful as the global list system is dependent on it. Functionality may break if you don't add this (towards the end of the files)
#for_TYPE_artifacts_no_arguments <- Useful for tinkering
# These can be copied from an existing slot or type; just change the TYPE in their name to match your type.
# Then add your type to listify_all_typed_artifacts_as_flags, also in artifacts_custom.txt
# Finally add your type or slot to artifact_triggers.txt in the scripted_triggers folder.

### Artifact types: 
for_all_slots = { #APPLY = x
#SLOTS: See also for_all_artifact_slots below
    $APPLY$ = {TYPE = handheld}
    $APPLY$ = {TYPE = armor}
    $APPLY$ = {TYPE = headgear}
    $APPLY$ = {TYPE = jewelry}
    $APPLY$ = {TYPE = mount}
}
for_all_non_slots = {#APPLY = x
#NON-SLOTS: See also for_all_artifact_types below
    $APPLY$ = {TYPE = shard}
    $APPLY$ = {TYPE = fabrial}
    $APPLY$ = {TYPE = indestructible}
}
for_all_rarities = {#APPLY = x
#NON-SLOTS:
    $APPLY$ = {TYPE = rarity_1}
    $APPLY$ = {TYPE = rarity_2}
    $APPLY$ = {TYPE = rarity_3}
    $APPLY$ = {TYPE = rarity_4}
}
for_all_subtypes = {#APPLY = x
    for_all_slots = {APPLY = $APPLY$}
    for_all_non_slots = {APPLY = $APPLY$}
}
#Make a global list for all subtypes:
listify_all_typed_artifacts_as_flags = { #USAGE yes
    listify_typed_artifacts_as_flags = {TYPE = all}
    for_all_subtypes = {APPLY = listify_typed_artifacts_as_flags}
    for_all_rarities = {APPLY = listify_typed_artifacts_as_flags}
}

## Artifact slot types:
# DOES NOT DEFINE A SLOT IN FULL GENERALITY ON ITS OWN.
for_all_artifact_slots = {
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = handheld }
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = armor }
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = headgear }
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = jewelry }
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = mount }
}

for_all_artifact_types = { #USAGE {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = a B = b TYPE = string}
    for_all_artifact_slots = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ }
## Non-slot types
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = shard }
    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = fabrial }
#    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = rarity_1 }
#    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = rarity_2 }
#    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = rarity_3 }
#    for_all_artifacts_of_type = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$ TYPE = rarity_4 }
}
for_all_artifacts_of_type = { #USAGE {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = a B = b TYPE = string}
    for_$TYPE$_artifacts = {PREFIX = $PREFIX$ APPLY = $APPLY$ SUFFIX = $SUFFIX$  A = $A$ B = $B$}
}

## Artifacts by slots - your new artifact should probably be somewhere in one of these lists.
for_handheld_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = a B = b}
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_4$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_5$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_6$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_7$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_16$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_17$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_18$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_19$SUFFIX$ A = $A$ B = $B$ } 
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_20$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_21$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_22$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_23$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_24$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_25$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_26$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_27$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_oathbringer$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_sunraiser$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_mayalaran$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_shardblade$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_nightblood$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_jezrien_honorblade$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_type_four_biochromatic_entity$SUFFIX$ A = $A$ B = $B$ }
}
for_armor_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = a B = b}
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_28$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_29$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_30$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_31$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_shardplate$SUFFIX$ A = $A$ B = $B$ }
}
for_headgear_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = a B = b}
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_1$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_2$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_3$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_8$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_9$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_10$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_11$SUFFIX$ A = $A$ B = $B$ }
}
for_jewelry_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = a B = b}
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_12$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_13$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_14$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_15$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_soulcaster$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_spanreed$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_painrial$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_alerter$SUFFIX$ A = $A$ B = $B$ }
}
for_mount_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_ryshadium$SUFFIX$ A = $A$ B = $B$ }
}

## Artifact types unrelated to equipment slots.
# Can be nested, but be warned that only a bottom-level command can be directly code injected with fancy strings.
for_shard_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
#Shardblades
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_oathbringer$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_sunraiser$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_mayalaran$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_shardblade$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_nightblood$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_jezrien_honorblade$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_type_four_biochromatic_entity$SUFFIX$ A = $A$ B = $B$ }
#Shardplates
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_shardplate$SUFFIX$ A = $A$ B = $B$ }
}
#Fabrials
for_fabrial_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_soulcaster$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_spanreed$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_painrial$SUFFIX$ A = $A$ B = $B$ }
    $APPLY$ = {ARTIFACT = $PREFIX$artifact_alerter$SUFFIX$ A = $A$ B = $B$ }
}
#Indestructibles
for_indestructible_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
#Shardblades
$APPLY$ = {ARTIFACT = $PREFIX$artifact_oathbringer$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_sunraiser$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_mayalaran$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_shardblade$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_nightblood$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_jezrien_honorblade$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_type_four_biochromatic_entity$SUFFIX$ A = $A$ B = $B$ }
#Shardplates
$APPLY$ = {ARTIFACT = $PREFIX$artifact_shardplate$SUFFIX$ A = $A$ B = $B$ }
}

for_rarity_4_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_1$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_2$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_3$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_7$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_11$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_15$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_19$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_23$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_27$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_31$SUFFIX$ A = $A$ B = $B$ }
}
for_rarity_3_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_6$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_10$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_14$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_18$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_22$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_26$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_30$SUFFIX$ A = $A$ B = $B$ }
}
for_rarity_2_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_5$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_9$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_13$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_17$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_21$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_25$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_29$SUFFIX$ A = $A$ B = $B$ }
}
for_rarity_1_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_4$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_8$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_12$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_16$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_20$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_24$SUFFIX$ A = $A$ B = $B$ }
$APPLY$ = {ARTIFACT = $PREFIX$artifact_28$SUFFIX$ A = $A$ B = $B$ }
}
## START OF MANDATORY COMMAND FOR NEW SLOTS
# None of the arguments may be empty:
for_all_artifacts = { #USAGE {PREFIX = X APPLY = Y SUFFIX = Z A = A TO = B }
    for_handheld_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = $SUFFIX$
        A = $A$ 
        B = $B$
    }
    for_armor_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = $SUFFIX$
        A = $A$ 
        B = $B$
    }
    for_headgear_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = $SUFFIX$
        A = $A$ 
        B = $B$
    }
    for_jewelry_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = $SUFFIX$
        A = $A$ 
        B = $B$
    }
    for_mount_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = $SUFFIX$
        A = $A$ 
        B = $B$
    }
}


## START OF NON-MANDATORY BUT USEFUL SIMPLIFYING COMMANDS FOR TYPES
# I lack a suffix:
for_handheld_artifacts_prefix = { #USAGE {PREFIX = X APPLY = Y A = A TO = B }
    for_handheld_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_armor_artifacts_prefix = {
    for_armor_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_headgear_artifacts_prefix = {
    for_headgear_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_jewelry_artifacts_prefix = {
    for_jewelry_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_mount_artifacts_prefix = {
    for_mount_artifacts = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_all_artifacts_prefix = {
    for_handheld_artifacts_prefix = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        A = $A$ 
        B = $B$
    }
    for_armor_artifacts_prefix = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        A = $A$ 
        B = $B$
    }
    for_headgear_artifacts_prefix = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        A = $A$ 
        B = $B$
    }
    for_jewelry_artifacts_prefix = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        A = $A$ 
        B = $B$
    }
    for_mount_artifacts_prefix = {
        APPLY = $APPLY$
        PREFIX = $PREFIX$
        A = $A$ 
        B = $B$
    }
}
# I lack prefix and suffix:
for_handheld_artifacts_nofix = {
    for_handheld_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_armor_artifacts_nofix = {
    for_armor_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_headgear_artifacts_nofix = {
    for_headgear_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_jewelry_artifacts_nofix = {
    for_jewelry_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_mount_artifacts_nofix = {
    for_mount_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_shard_artifacts_nofix = {
    for_shard_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_fabrial_artifacts_nofix = {
    for_fabrial_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_indestructible_artifacts_nofix = {
    for_indestructible_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_rarity_4_artifacts_nofix = {
    for_rarity_4_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_rarity_3_artifacts_nofix = {
    for_rarity_3_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_rarity_2_artifacts_nofix = {
    for_rarity_2_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_rarity_1_artifacts_nofix = {
    for_rarity_1_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = ""
        A = $A$ 
        B = $B$
    }
}
for_all_artifacts_nofix = {
    for_handheld_artifacts_nofix = {
        APPLY = $APPLY$
        A = $A$ 
        B = $B$
    }
    for_armor_artifacts_nofix = {
        APPLY = $APPLY$
        A = $A$ 
        B = $B$
    }
    for_headgear_artifacts_nofix = {
        APPLY = $APPLY$
        A = $A$ 
        B = $B$
    }
    for_jewelry_artifacts_nofix = {
        APPLY = $APPLY$
        A = $A$ 
        B = $B$
    }
    for_mount_artifacts_nofix = {
        APPLY = $APPLY$
        A = $A$ 
        B = $B$
    }
}
# For use when you want a custom function but you don't want to pass prefixes nor extra arguments
for_handheld_artifacts_no_arguments = {
    for_handheld_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_armor_artifacts_no_arguments = {
    for_armor_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_headgear_artifacts_no_arguments = {
    for_headgear_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes
        B = yes
    }
}
for_jewelry_artifacts_no_arguments = {
    for_jewelry_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_mount_artifacts_no_arguments = {
    for_mount_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_all_artifacts_no_arguments = {
    for_handheld_artifacts_no_arguments = {APPLY = $APPLY$ }
    for_armor_artifacts_no_arguments = {APPLY = $APPLY$ }
    for_headgear_artifacts_no_arguments = { APPLY = $APPLY$ }
    for_jewelry_artifacts_no_arguments = {APPLY = $APPLY$ }
    for_mount_artifacts_no_arguments = {APPLY = $APPLY$ }
}
for_shard_artifacts_no_arguments = {
    for_shard_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_fabrial_artifacts_no_arguments = {
    for_fabrial_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_indestructible_artifacts_no_arguments = {
    for_indestructible_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_rarity_4_artifacts_no_arguments = {
    for_rarity_4_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_rarity_3_artifacts_no_arguments = {
    for_rarity_3_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_rarity_2_artifacts_no_arguments = {
    for_rarity_2_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}
for_rarity_1_artifacts_no_arguments = {
    for_rarity_1_artifacts = {
        APPLY = $APPLY$
        PREFIX = ""
        SUFFIX = "}#"
        A = yes 
        B = yes
    }
}