Gemstone Logo

Legendary
Gemstones

Datapack Configuration

Gemstone Modifiers

Gemstone modifier configs define the bonuses that each gemstone gives to each item category.

data/gemstones/gemstones/topaz.json
{
  "gemstone_type": "TOPAZ",
  "modifiers": {
    "MELEE": {
      "type": "ATTRIBUTE",
      "attribute_id": "gemstones:crit_damage",
      "value_levels": [0.25, 0.3, 0.35, 0.4],
      "operation": "ADD_MULTIPLIED_TOTAL"
    },
    "RANGED": {
      "type": "ON_HIT_EFFECT_PROJECTILE",
      "chance_levels": [0.1, 0.14, 0.19, 0.25],
      "effect_id": "gemstones:radiance",
      "duration": 24,
      "amplifier": 0,
      "is_stacking": false,
      "max_stack_count": 0
    },
    "TOOLS": {
      "type": "ON_BEFORE_BLOCK_BREAK",
      "chance_levels": [0.2, 0.3, 0.4, 0.5],
      "value_levels": [0.0, 0.0, 0.0, 0.0],
      "event_type": "ON_BLOCK_BREAK_SMELTER"
    },
    "ARMOR": {
      "type": "MULTIPLY_ATTRIBUTE",
      "instances": [
        {
          "attribute_id": "minecraft:generic.armor",
          "value_levels": [1.0, 1.5, 2.0, 2.5],
          "operation": "ADD_VALUE"
        },
        {
          "attribute_id": "minecraft:generic.armor_toughness",
          "value_levels": [0.9, 1.4, 1.9, 2.4],
          "operation": "ADD_VALUE"
        }
      ]
    }
  }
}

Prop

Type


Categories

Each gemstone can define category entries under modifiers. ALL is a fallback category used when the item-specific category does not have a modifier.

Prop

Type

If a gemstone doesn't define a modifier for a category, it simply won't give bonuses on items of that category.

ALL category used only for amplifier gemstones currently. Using ALL for non-amplifier gemstones can cause unintended interactions.


Level Values

Most numeric modifier fields are arrays. Values are read by gemstone quality:

Prop

Type

"value_levels": [1.0, 2.0, 3.0, 4.0]

Mythic gemstones use the first value in each array, so mythic configs usually contain a single number:

"value_levels": [10.0]

If a normal quality asks for a missing index, the loader falls back to the first value.

Prop

Type


Modifier Types

ATTRIBUTE

Adds one Minecraft attribute modifier.

{
  "type": "ATTRIBUTE",
  "attribute_id": "minecraft:generic.max_health",
  "value_levels": [1.0, 2.0, 3.0, 4.0],
  "operation": "ADD_VALUE"
}

Prop

Type

MULTIPLY_ATTRIBUTE

Applies several attribute modifiers from one category entry.

{
  "type": "MULTIPLY_ATTRIBUTE",
  "instances": [
    {
      "attribute_id": "minecraft:generic.attack_damage",
      "value_levels": [1.0, 1.4, 1.8, 2.2],
      "operation": "ADD_VALUE"
    },
    {
      "attribute_id": "minecraft:generic.attack_speed",
      "value_levels": [-0.15, -0.2, -0.28, -0.35],
      "operation": "ADD_MULTIPLIED_TOTAL"
    }
  ]
}

Prop

Type

ON_HIT_MELEE

Runs an event when the player hits a target with a melee attack.

{
  "type": "ON_HIT_MELEE",
  "chance_levels": [0.1, 0.15, 0.2, 0.25],
  "event_type": "ON_HIT_LIFE_STEAL"
}

ON_HIT_PROJECTILE

Runs an event when the player's projectile hits a target.

{
  "type": "ON_HIT_PROJECTILE",
  "chance_levels": [0.12, 0.18, 0.24, 0.32],
  "event_type": "ON_HIT_ARROW_RAIN"
}

Prop

Type

ON_HIT_EFFECT_MELEE

Applies a status effect to the target on melee hit.

{
  "type": "ON_HIT_EFFECT_MELEE",
  "chance_levels": [0.1, 0.15, 0.2, 0.25],
  "effect_id": "gemstones:bleeding",
  "duration": 60,
  "amplifier": 0,
  "is_stacking": true,
  "max_stack_count": 4
}

ON_HIT_EFFECT_PROJECTILE

Applies a status effect to the target on projectile hit.

{
  "type": "ON_HIT_EFFECT_PROJECTILE",
  "chance_levels": [0.1, 0.14, 0.19, 0.25],
  "effect_id": "gemstones:radiance",
  "duration": 24,
  "amplifier": 0,
  "is_stacking": false,
  "max_stack_count": 0
}

Prop

Type

AREA_EFFECT

Applies a status effect to entities in range while the gemstone is active.

{
  "type": "AREA_EFFECT",
  "radius_levels": [4.0, 5.0, 6.0, 7.0],
  "effect_id": "minecraft:resistance",
  "duration": 6,
  "amplifier": 0,
  "not_me": false,
  "only_players": true
}

Prop

Type

AMPLIFIER

Amplifies next socket's modifier values. Amplifier gemstones use the ALL category so same config can apply regardless of item category.

{
  "type": "AMPLIFIER",
  "value_levels": [0.15, 0.25, 0.35, 0.55]
}

Prop

Type

Event Modifiers

These modifier types all use event_type, value_levels, and optional additional_value_levels. ON_HIT_MELEE and ON_HIT_PROJECTILE are the exception: they use chance_levels as their primary array.

Prop

Type

ON_BLOCK_BREAK
{
  "type": "ON_BLOCK_BREAK",
  "chance_levels": [0.1, 0.2, 0.3, 0.4],
  "value_levels": [1.0, 1.0, 2.0, 2.0],
  "event_type": "ON_BLOCK_BREAK_HEAL"
}
ON_PLAYER_DAMAGE
{
  "type": "ON_PLAYER_DAMAGE",
  "value_levels": [60.0],
  "additional_value_levels": [6.0],
  "event_type": "PLAYER_SAVE_LETHAL"
}

Prop

Type


Event Types

event_type accepts either the legacy uppercase name, such as ON_HIT_LIFE_STEAL, or a registry ID, such as gemstones:on_hit_life_steal.

Event modifier fields have a design issue in the current modifier system. Some events use chance_levels, value_levels or additional_value_levels as generic event arguments rather than values that match the field names literally. Check each event description before changing a config.

On-hit events

Prop

Type

Block break events

Prop

Type

Player and damage events

Prop

Type

Other events

Prop

Type

Special weapon events

Prop

Type


Status Effects

effect_id accepts vanilla status effect IDs and these registered mod effect IDs.

Prop

Type

Attributes

attribute_id accepts vanilla attribute IDs and these registered mod attribute IDs.

Prop

Type

On this page