Custom Accessory Types - Swackyy/Ohmega GitHub Wiki

Basic

You can create custom accessory types with any Mod or Data Pack, simply by following this file structure:

.
└── data/
    └── yourModID/
        └── ohmega/   --- This must be "ohmega"
            └── accessory_types.json

Inside of the file, follow this Json structure:

{
  "myAccessoryType": {
    "emptySlotTexture": "item/myEmptySlotFile"
  }
}

With that, the API is now aware of your custom Accessory Type, and you can edit the server config to add a slot of this type

Advanced (all recognised data fields)

Empty Slot Texture ("emptySlotTexture")

A string in the form of a resource location that will use a data-pack namespace (mod Id) provided (e.g. "exId:item/mySlotIcon") but will default to your namespace if there is not one provided (e.g. "exId" as the namespace will cause "item/mySlotIcon" to parse to "exId:item/mySlotIcon")

Type: String

Default: "ohmega:item/accessory_slot_normal"

Color ("color")

The color of text that will be displayed when hovering over an empty slot of this type

Type: Integer

Default: 16777215 (decimal) 0xffffff (hex)

Priority Index ("priority")

If an accessory has multiple accessory type tags, the one with the lowest priority index will win, and that one will be used.

Accessory Types can also be directly overridden using the `

E.g. If accessory type "type1" has priority index of 10 and "type2" has priority index of 3, accessories with both of these types will only use type2

Type: Positive Integer

Default: 0

Display Hover Text ("displayHoverText")

If true, will display the translation for the accessory type when hovering over a matching accessory slot and accessory tooltips displaying the type as this one will be shown, else, no text will be shown

Type: Boolean

Default: true