I decided to start messing around with adding enchants to weapons and the very first thing I tried was veil piercing. The recipe works, I can apply the enchant successfully and the weapon then shows the veil piercing text on its description but when I strike a phantom with it, the "-50% Veil-Touched" reduction still occurs. I used the same veil piercing item mod that's used on existing items but it just doesn't seem to work. I also tried just adding the modifier to a weapon directly and it didn't work there either.
I think I must be missing something obvious but having not messed around with item mods before I'm not sure what, so any help or suggestions would be greatly appreciated.
Here's the code I used to add the recipe:
{
"GameDataObjects": [
{
"$type": "Game.GameData.RecipeData, Assembly-CSharp",
"DebugName": "Recipe_Veil_Piercing",
"ID": "e23b1d67-4d21-4665-846f-b243db1b0032",
"Components": [
{
"$type": "Game.GameData.RecipeComponent, Assembly-CSharp",
"DisplayName": 339228844,
"CraftingLocation": "None",
"CategoryID": "7bad3803-0dfd-473a-a857-326f4853a4d6",
"VisibilityConditions": {
"Operator": 0,
"Components": []
},
"CreationConditions": {
"Operator": 0,
"Components": [
{
"$type": "OEIFormats.FlowCharts.ConditionalCall, OEIFormats",
"Data": {
"FullName": "Boolean HasItemMod(Guid)",
"Parameters": [
"9dca49ce-06e1-443f-9011-5e2d321a0c01"
],
"Flags": "",
"UnrealCall": "",
"FunctionHash": 1518072523,
"ParameterHash": 281095213
},
"Not": true,
"Operator": 0
}
]
},
"Cost": 3000,
"CostByValueMultiplier": 0,
"Double2HIngredientCost": "true",
"CanModifyWeapons": "false",
"CanModifyArmor": "false",
"CanModifyShields": "false",
"CanModifySpecificItemsIDs": [
"193012c0-e145-4baa-b33b-b432927badc6",
"f0778b9e-3bef-4a96-82c6-31fcbbdf3d1b",
"8a0fa46c-f325-4929-a7f7-a022d2bde11b",
"1bdac16d-6d87-4677-a1ae-185ed5915496",
"9fa78d07-b392-4b09-ba52-941e22e79876",
"063d7aa7-d0be-431e-8dcb-da6136161b7f"
],
"Ingredients": [
{
"ItemID": "0e274db1-566d-46c8-b485-4392e0c9553f",
"Quantity": 1,
"IsDestroyed": "true"
},
{
"ItemID": "f163ffbf-9539-4e6e-ab78-33fb5519066e",
"Quantity": 1,
"IsDestroyed": "true"
},
{
"ItemID": "3ca52b87-0531-4402-a3e3-bf4b56847387",
"Quantity": 1,
"IsDestroyed": "true"
}
],
"Output": [],
"PrerequisiteItemModID": "00000000-0000-0000-0000-000000000000",
"ItemModsToAddIDs": [
"9dca49ce-06e1-443f-9011-5e2d321a0c01"
],
"ItemModsToRemoveIDs": []
}
]
}
]
}