Skip to content

Custom Drops

Yevhen Harasymchuk edited this page Jul 29, 2026 · 2 revisions

Use a global Skript function as a MythicMobs drop entry. Both skfunction and skriptfunction are accepted drop names.

Function Contract

The function receives exactly two parameters in this order:

  1. dropdata — the current MythicMobs DropMetadata;
  2. number — the amount/value requested by MythicMobs.

Return an itemstack to register an item drop. Return text to register a reward-message drop. Returning nothing produces no item/message.

Item Drop

function scripted_item(data: dropdata, amount: number) :: itemstack:
    set {_item} to diamond named "Scripted Diamond"
    set item amount of {_item} to {_amount}
    return {_item}

Use it in a MythicMobs drop table:

ScriptedDrops:
  Drops:
  - skfunction{name=scripted_item} 2 1

Reward Message Drop

function scripted_message(data: dropdata, amount: number) :: text:
    return "Custom reward value: %{_amount}%"
MessageDrops:
  Drops:
  - skriptfunction{n=scripted_message} 1 1

See Expressions for the values available from dropdata.

Clone this wiki locally