Jump to content

Mod Loader/Accessories

From WikiName

An accessory can be placed on a dress, or repeated along a trim path. A pack can include its model, texture, shop icon, price, and tags.

Try the cat example

Download the Oiia Cat example ZIP. It has two items: a cat you place once and a row of smaller cats you draw as trim. Install it through Mod Manager, restart, and find both in the accessory shop. Open the ZIP to see its mod.json, meshes, texture, and icon.

Pack files

Make a folder under Dressmaker/Mods. These names match the Oiia Cat example; change them to match your own files.

Dressmaker/
└── Mods/
    └── MyAccessoryPack/
        ├── mod.json
        ├── icon.png
        ├── cat-texture.png
        ├── cat-single.mesh.json
        └── cat-trim.mesh.json

Put this in mod.json. It registers one placeable accessory and one repeating trim using those files:

{
  "id": "yourname.cat-pack",
  "name": "My Cat Pack",
  "author": "Your Name",
  "version": "1.0.0",
  "icon": "icon.png",
  "accessories": [
    {
      "id": "cat",
      "name": "Cat",
      "baseAccessory": "Applique Luna Moth",
      "accessoryType": "Other",
      "model": "cat-single.mesh.json",
      "texture": "cat-texture.png",
      "icon": "icon.png",
      "cost": 10,
      "unlockLevel": 0,
      "tagWeights": [{ "tag": "Cute", "weight": 10 }]
    },
    {
      "id": "cat-trim",
      "name": "Cat Parade",
      "baseAccessory": "Trim Pearl Beads",
      "accessoryType": "Trim",
      "model": "cat-trim.mesh.json",
      "texture": "cat-texture.png",
      "icon": "icon.png",
      "cost": 2,
      "unlockLevel": 0,
      "beadSpacing": 0.04
    }
  ]
}

baseAccessory supplies the game's placement behavior. Use a single-item base for an item you place once, and a trim base for something repeated along a path. accessoryType controls its shop category. model, texture, and icon are filenames inside this pack folder. unlockLevel: 0 makes the item available from the start.

The pack ID and each item ID form the saved item identity. Change them when you copy the example to make a new mod; keep them when you update one you've shared. The field reference covers other fields, including materials and reuseAsset.

Mesh JSON

The game does not load an OBJ or FBX from the pack. Export the model as .mesh.json. The file has three arrays: positions holds X, Y, Z values in metres; uvs holds U, V texture coordinates; and triangles holds zero-based vertex indices. This tiny example is one triangle:

{
  "positions": [-0.02, 0, 0, 0.02, 0, 0, 0, 0.04, 0.005],
  "uvs": [0, 0, 1, 0, 0.5, 1],
  "triangles": [0, 1, 2]
}

Use the mesh files from Oiia Cat to see a real model. The single cat has 15,774 triangles: treat it like a detailed one-off prop, rather than a small bow or bead. The trim cat has 3,494 per copy, much more geometry than the simple shapes usually repeated along an in-game trim. Twenty cats along a path are about 70,000 triangles before counting the dress, so simplify a model that will repeat often. These are the example's counts; the game's accessory reference does not include native mesh counts for a numerical average. The accessory reference includes a Blender export script and explains how to orient and size a model.

Make a trim

The loader repeats the mesh along the path. Set beadSpacing to the approximate distance between copies, in metres, at the default width. Here 0.04 means about 4 cm. The game's trim width control also scales the spacing. Try a short path and a curved one; the copies may overlap on tight bends.

Mesh positions are in metres. The example faces +Z out from the dress. Use it to check your model's size and direction.

Test and update

  1. Install the pack and restart Dressmaker.
  2. Find the item in the accessory shop, buy it, and place it on a dress.
  3. For trim, draw a path and change its width.
  4. Save the dress, reopen it, and check the model and icon.

Keep pack and item IDs the same when updating. Saved dresses can refer to them.

Field reference

The accessory fields page has the full Blender script, material options, limits, and the Oiia Cat notes. Native accessory names and tags are in BepInEx/config/DressmakerMods/accessory-reference.json, which the loader writes when it starts.

Back to the Mod Loader guide