give_random_item

Gives the player one randomly chosen item from a list, optionally placing it into a specific inventory slot.

Categories: inventory

Required arguments

Key(s)DescriptionType
items \| itemThe pool of items to choose from. One is picked at random per trigger.ITEM_LIST

Optional arguments

Key(s)DescriptionTypeDefault
slotThe inventory slot type to place the item into. If omitted the item is dropped into the player's inventory via telekinesis.STRING

Trigger parameters required

  • PLAYER

Example

effects:
  - id: give_random_item
    args:
      items:
        - <value>
      slot: mainhand # ← Optional

Behaviour

SettingValue
Run orderNORMAL
Supports delaytrue
Reloads on plugin reloadtrue