Form/Fusion Configuration (transformations.json)
This file allows defining custom rules for Pokémon form changes and fusions triggered by items or interactions within the Myths and Legends mod.
Location: `<Your Minecraft Folder>/config/mythsandlegends/transformations.json` Format: JSON (JavaScript Object Notation)
The file is automatically generated with a set of default rules if it doesn't exist (see Default File Contents below). You can modify these defaults or add new rules following the structure defined below.
Validation
When the mod loads this file, it performs validation checks on each rule:
- It verifies that the Pokémon names specified correspond to actual Pokémon species loaded by Cobblemon.
- It checks if the specified `targetForm` or `resultingForm` names are valid forms for the respective Pokémon species.
- It ensures that the specified `item` identifiers correspond to actual registered items in the game.
- It checks if the `playAnimation` and `isTradable` fields are valid booleans.
If any part of a rule is found to be invalid (e.g., misspelled Pokémon name, non-existent form, invalid item ID), that specific rule will be ignored and removed from the loaded configuration. A warning message detailing the invalid rule will be printed to the server console/log.
JSON Structure
The main JSON structure is an object containing three lists: `heldItemChanges`, `interactionChanges`, and `fusions`.
{ "heldItemChanges": [], "interactionChanges": [], "fusions": [] }
heldItemChanges
Rules in this list define form changes that occur when a Pokémon is holding a specific item.
Structure
Each rule is an object with the following fields:
- pokemon (String): The name of the base Pokémon species (e.g., “giratina”). Must match Cobblemon's internal name (case-insensitive).
- item (String): The identifier of the item that must be held (e.g., “mythsandlegends:griseous_orb”).
- targetForm (String): The name of the form the Pokémon should change into while holding the item (e.g., “origin”). Must be a valid form name for the specified Pokémon.
- playAnimation (Boolean): Set to `true` to play a visual form change animation, `false` for an instant change.
- isTradable (Boolean): Set to `true` if the Pokémon in this target form should be tradable, `false` otherwise.
Example
{ "pokemon": "giratina", "item": "mythsandlegends:griseous_orb", "targetForm": "origin", "playAnimation": true, "isTradable": false }
This rule would change Giratina to its Origin Forme when holding the Griseous Orb, play an animation, and make the Origin Forme untradable.
interactionChanges
Rules in this list define form changes triggered when a specific item is used (right-clicked) on a Pokémon.
Structure
Each rule is an object with the following fields:
- pokemon (String): The name of the Pokémon species to interact with (e.g., “hoopa”).
- item (String): The identifier of the item used for interaction (e.g., “mythsandlegends:prison_bottle”).
- targetForm (String): The name of the form the Pokémon should change into after the interaction (e.g., “unbound”).
- playAnimation (Boolean): Set to `true` to play a visual form change animation, `false` for an instant change.
- isTradable (Boolean): Set to `true` if the Pokémon in this target form should be tradable, `false` otherwise.
Example
{ "pokemon": "hoopa", "item": "mythsandlegends:prison_bottle", "targetForm": "unbound", "playAnimation": true, "isTradable": false }
This rule could change Hoopa to its Unbound Forme when right-clicked with a Prison Bottle, play an animation, and make the Unbound Forme untradable.
fusions
Rules in this list define form changes (fusions) triggered when an item is used on a 'base' Pokémon while a specific 'partner' Pokémon is present in the player's party.
Structure
Each rule is an object with the following fields:
- basePokemon (String): The name of the Pokémon species being interacted with (e.g., “kyurem”).
- partnerPokemon (String): The name of the Pokémon species that must also be in the player's party (e.g., “zekrom”).
- item (String): The identifier of the item used for the fusion interaction (e.g., “mythsandlegends:dna_splicer”).
- resultingForm (String): The name of the form the `basePokemon` should change into after the successful fusion (e.g., “black”).
- playAnimation (Boolean): Set to `true` to play a visual fusion animation, `false` for an instant change.
- isTradable (Boolean): Set to `true` if the Pokémon in the resulting fused form should be tradable, `false` otherwise.
Example
{ "basePokemon": "kyurem", "partnerPokemon": "zekrom", "item": "mythsandlegends:dna_splicer", "resultingForm": "black", "playAnimation": true, "isTradable": false }
This rule would change Kyurem to Kyurem-Black when right-clicked with DNA Splicers while Zekrom is also in the party, play an animation, and make Kyurem-Black untradable.
Default File Contents
When the mod first runs or if this file is deleted, it will be created with the following default set of rules:
{ "heldItemChanges": [ { "pokemon": "dialga", "item": "mythsandlegends:adamant_orb", "targetForm": "origin", "playAnimation": true, "isTradable": false }, { "pokemon": "palkia", "item": "mythsandlegends:lustrous_orb", "targetForm": "origin", "playAnimation": true, "isTradable": false }, { "pokemon": "giratina", "item": "mythsandlegends:griseous_orb", "targetForm": "origin", "playAnimation": true, "isTradable": false } ], "interactionChanges": [ { "pokemon": "hoopa", "item": "mythsandlegends:prison_bottle", "targetForm": "unbound", "playAnimation": true, "isTradable": false }, { "pokemon": "tornadus", "item": "mythsandlegends:reveal_glass", "targetForm": "therian", "playAnimation": true, "isTradable": true }, { "pokemon": "thundurus", "item": "mythsandlegends:reveal_glass", "targetForm": "therian", "playAnimation": true, "isTradable": true }, { "pokemon": "landorus", "item": "mythsandlegends:reveal_glass", "targetForm": "therian", "playAnimation": true, "isTradable": true }, { "pokemon": "enamorus", "item": "mythsandlegends:reveal_glass", "targetForm": "therian", "playAnimation": true, "isTradable": true } ], "fusions": [ { "basePokemon": "calyrex", "partnerPokemon": "spectrier", "item": "mythsandlegends:reins_of_unity", "resultingForm": "shadow", "playAnimation": true, "isTradable": false }, { "basePokemon": "calyrex", "partnerPokemon": "glastrier", "item": "mythsandlegends:reins_of_unity", "resultingForm": "ice", "playAnimation": true, "isTradable": false }, { "basePokemon": "kyurem", "partnerPokemon": "reshiram", "item": "mythsandlegends:dna_splicer", "resultingForm": "white", "playAnimation": true, "isTradable": false }, { "basePokemon": "kyurem", "partnerPokemon": "zekrom", "item": "mythsandlegends:dna_splicer", "resultingForm": "black", "playAnimation": true, "isTradable": false } ] }
You can modify these default rules (e.g., change `playAnimation` or `isTradable`), remove them, or add your own custom rules following the specified structures.