Skip to content

How To Add Wingworks Support for a Model

Drathonix edited this page Aug 20, 2026 · 9 revisions

For this tutorial I will be using Featherborn's avian player model. Download the most recent mod version if you wish to follow along. If you do not already have a zip modification program installed I recommend you get one. I am using 7zip for windows.

This tutorial requires at minimum Wingworks 1.1.5.

Adding Wingworks Flight Support

Every mod which implements a custom player model lib (PML) player model works relatively the same way. All important files can be located in the mod's assets directory, in featherborn's case this is "assets/featherborn" and this is what it looks like: image

Models store information in multiple places but the two most important locations are the "shapes" and "config" directories. Let's start with the config directory since this is where the player model types are declared. image

The location we want to look into is the "customplayermodels" directory but you should be aware that "model-replacements-byshape.json" handles changing clothing and armor models depending on the player's current model, you likely won't need this for wingworks but it is good to know. Opening up the "customplayermodels" directory we see this:

image

Each of these files corresponds to a separate PML custom model type and contains the information PML needs to add the custom model to the game. In our case we want to grant the avian model wingworks support. That's simple, lets open "avian-player.json"

image

This is all you need to see from the file. In order for this model to support wingworks flight the "ww_flight" trait must be added to the models "ExtraTraits" array. Unfortunately for us there is no "ExtraTraits" array, there are two solutions to this and I will show you both.

Option 1: Modifying the file directly

In this example we will just modify the json file directly. There are some downsides to doing this, first of all if wingworks is not installed the model will still have the trait which is harmless but the trait will appear in GUIs which may confuse users, second of all it prevents disabling the feature easily. A good example of this is found in KC's Dragons which uses a config to give people the ability to disable Wingworks flight, you may want to take this approach. Configs are beyond the scope of this tutorial so I'll skip to the good part. Here's the steps:

  1. Extract the mod zip if you have not done so already.
  2. Locate the model JSON file you wish to modify, "avian-player.json" in this case.
  3. Add the trait. In this case we must also add an "ExtraTraits" array like so: (make sure not to forget commas!)
image
  1. Save the file.
  2. Rezip the mod using your zip program. This new file should be Wingworks compatible.

Option 2: JSON Patching

JSON Patching is a feature provided by the VS Modding API that provides a way for mods to make changes to JSON assets provided by mods and the game itself without having to modify the source files. Patch files also are JSON files In this case I will create the full file and explain it for you

[
  {
    "file": "featherborn:config/customplayermodels/avian-player.json",
    "op": "addmerge",
    "path": "/avian",
    "dependsOn": [ { "modid": "wingworks" } ],
    "value": {
      "ExtraTraits": ["ww-flight"]
    }
  }
]
  1. file - this is the target asset file the path "assets/featherborn/config/customplayermodels/avian-player.json" is converted to "featherborn:config/customplayermodels/avian-player.json", following the format :.
  2. op - short for operation. The "addmerge" operation adds the value to the end of the target location safely. There are other operations as well just so you are aware, check out the VS wiki for more info if you are interested.
  3. path - The path within the target JSON to modify. As a more complicated example if we have a file {"a":[0,1,{"b":"c"}]} and we want to remove the value "c" the path would be "/a/2/b" where a and b are keys in a {map} and 2 is an index in an [array].
  4. dependsOn - Controls if this JSON patch should run. As a side note if a JSON patch fails to run the game will log an error and in some cases it may cause a crash if a mod depends on that JSON patch working. In this case the patch only runs in wingworks is present.
  5. value - The value we want to add to the dictionary. If you're adding a value to an array the value would be an array indicated with angle brackets []. If you're adding a value to a map it would be indicated with curly braces {}. In this case we're adding a map entry so we provide a key-value pair stored within a map.

Anyways this file must be saved in our mod's assets//patches directory in this case I'm calling it "avian-player-patch.json"

Testing

I'm going to assume you used option 2, but if you didn't don't worry both options have the same result! This is the mod file I created for the tutorial: avianwingworks-1.0.0.zip After adding it to the mods folder this is what the character creation screen looks like:

image

As you can see, if the "Flyer" trait appears its working!

Unfortunately, the Featherborn mod lacks support for gliding and flying animations so your character will just fly without them. I'll make an animation patching tutorial in the future but be warned that if you have not created animations for vintage story this may be difficult for you.