Creating a config - SeaSparrowOG/EnchantmentArtExtender GitHub Wiki

What are configs

Configs are JSON files found inside Data/Enchantment Art Extender/. Any JSON file there is considered to be a config file by the framework. Configs follow rules, but if you get anything wrong, the framework will try its best to let you know what happened.

Setting up a custom art

Arts are, in essence, abilities with magic hit effects that are dynamically applied and removed. A simple setup looks like this: Screenshot_69 Screenshot_70 Screenshot_71 These were formatted using Vibrant Weapons as a base. Right now, the plugin does not validate them to make sure they work, but will do so in a near release.

Rules - Top Level

Now that you have your art ready, you must create a config file to have it apply in the game. There are 2 sections inside the config file, the top level and the swap data. This section will go over the top level.

{
  "MinimumVersion":1,
  "Exclusive": true,
  "EnchantmentKeywords": [
    "MagicDamageFire"
  ],
  "ArtSource":"AwesomeMod.esp",
  "SwapData": [
  ]
}

For now, ignore "SwapData".

  • MinimumVersion Optional. The minimum version of the framework required by the config file. If missing, it is presumed to be 1. If the framework is outdated, this config will not be loaded. In order to get the framework's version, simply add its Major, Minor, and Patch numbers up which you can find in Documents/My Games/Skyrim Special Edition/SKSE/EnchantmentEffectsExtender.log. It will look like this: Plugin Version: 1.0.0.
  • Exclusive Optional. If true, the swaps in the folder will be considered "exclusive". If a weapon has an exclusive swap that can be applied, ONLY THAT SWAP will be added. If there are multiple exclusive swaps, the framework will do its best to find the one that fits that weapon the best.
  • EnchantmentKeywords Mandatory. An array containing strings. The swaps inside this config file will only be applied if the enchantments have ALL keywords.
  • ArtSource Mandatory. The name of the mod that contains the specified arts. Applies to all swaps in the file.

Rules - Swap Data

This is where the rules for the weapons are defined.

{
  "SwapData": [
    {
      "SwordFireSwap": {
        "Left": "0x804",
        "Right": "0x805",
        "WeaponKeywords": [
          "WeapTypeSword"
        ]
      }
    },
    {
      "GreatswordFireSwap": {
        "Left": "0x806",
        "Right": "0x806",
        "WeaponKeywords": [
          "WeapTypeGreatsword"
        ]
      }
    }
  ]
}

SwapData is an array of objects. Each object is an individual swap. Let's take a look at a specific object to keep things readable:

{
  "SwordFireSwap": {
    "Left": "0x804",
    "Right": "0x805",
    "WeaponKeywords": [
      "WeapTypeSword"
    ]
  }
}
  • SwordFireSwap Mandatory. The name of the swap, used for debugging. Also helps keep things slightly more readable. The JSON standard doesn't allow for comments anymore, so this is a decent middle ground.
  • Left Mandatory. This is the FormID of the art that will be applied when the actor equips a matching weapon in their left hand.
  • Right Mandatory. This is the FormID of the art that will be applied when the actor equips a matching weapon in their right hand.

Here I want you to notice how example 1 (Greatsword) is a 2-handed weapon. As such, it can only be equipped in the right hand. If you want to use a weapon of this type, or a weapon that can only be equipped in the right or left hand, you should STILL define both the left and right fields. They can use the same art, or an invalid art.

  • WeaponKeywords Mandatory. This is an array of keywords that they weapon needs to have.

There are a few undocumented fields that are valid and will have an effect but are not fully tested yet (ExcludedWeaponKeywords, RequiredWeapons, ExcludedWeapons). You can see how they are read in cache.cpp if you REALLY want to use them.