Cobblemon Gym Badges adds a Badge Press for crafting custom gym badges (and ribbons) with role-based access.
Cobblemon Gym Badges adds a Badge Press for crafting custom gym badges (and ribbons) with role-based access.
You need two parts:
Path: data/<namespace>/cgb/badge/<id>.json
(cgb here is the registry namespace for badges.)
Naming tip: the <id> is the badge’s identity and translation key.
If you want a “Champion Ribbon”, name the file champion_ribbon.json and add a translation for
badge.<namespace>.champion_ribbon. The internal item id is always cgb:badge, cgb:badge_ribbon,
or cgb:badge_untagged based on badgebox, but players only see the badge definition name.
Example (badge):
{
"name": { "text": "Fire Badge" },
"theme": "fire",
"texture": "cgb:item/fire_badge",
"badgebox": "badge"
}
Example (ribbon):
{
"name": { "text": "Champion Ribbon" },
"theme": "champion",
"texture": "cgb:item/blue_ribbon",
"badgebox": "ribbon"
}
Field overview:
name (optional): Display name component.theme (optional): Theme string. If omitted, uses the file name as the theme.role (optional): Required role name (without the gym_leader_ prefix).tags (optional): Extra item tags to apply to the badge item.model_data (optional): Custom model data value. If omitted, the mod auto-assigns a unique value per badgebox type.model or texture (optional): Item model id to use. If you set texture only, the mod generates the item model.badgebox (optional): none, badge, or ribbon.
badge is the default (adds badgebox:badges).ribbon adds badgebox:ribbons.none adds no BadgeBox tag.Path: data/<namespace>/recipe/<id>.json
Example:
{
"type": "cgb:badgemaking",
"core": { "item": "minecraft:gold_ingot" },
"base": { "item": "minecraft:blue_dye" },
"result": {
"theme": "champion"
}
}
core = top slot in the Badge Pressbase = bottom slot in the Badge PressPaths:
assets/<namespace>/textures/item/<id>.pngYou only need textures for simple 2D badges/ribbons. The mod generates the base item models and
CustomModelData overrides at runtime, so you do not need to ship badge.json, badge_ribbon.json,
or per-badge model files.
If your badge definition uses "texture": "cgb:item/blue_ribbon", you must also provide:
assets/cgb/textures/item/blue_ribbon.pngIf you want a custom item model (3D or layered), set "model": "<namespace>:item/<id>" in the badge definition
and include the model JSON yourself.
Model selection (how textures are chosen):
model_data is omitted, the mod auto-assigns unique values per badgebox type.You can still set model_data manually if you need stable IDs across packs, but it is not required.
world/datapacks/ and run /reload.resourcepacks/ and enable it in the Resource Packs menu.model, make sure the model id in your badge definition points at a real item model JSON.model_data manually, ensure each badge has a unique number per badgebox type.
Otherwise, let the mod auto-assign it.
Conversation