The cratest crate plugin of all time
3

Keys

Keys are things that are taken from a user when opening a crate. There is currently only one key type:

StandardKey

A key that is tracked virtually for each user.

<id> = {
    //name, lore, icon
}

Properties

NameTypeDescriptionDefault
nameTextThe key name, inherited from ComponentThis key’s capitalized id
loreListThe key lore, inherited from ComponentAn empty list
iconItemThe key icon, inherited from ComponentA tripwire_hook with the above name/lore
quantityIntegerThe reference value, which is the number of keys needed for that crateRequired

Referencing

The reference value of a key is the quantity, which is the number of keys needed for that crate and is required. Keys can also be defined inline using an object.

keys = [
    ["<key-id>", <quantity>]
    {
        quantity = <quantity>
    }
]

Keys can also be defined inline, though it’s recommended to define keys separately to customize name/lore/icon as needed.

keys = [
    ["<new-key-id>", <quantity>]
]

Examples

A standard key with name/lore/icon. Though the default icon is a tripwire_hook, this adds an enchantment effect for style points.

example = {
    name = "&eExample Key"
    lore = ["&6An example key"]
    icon = {
        type = "minecraft:tripwire_hook"
        enchantments = [
            ["minecraft:fortune", 1]
        ]
    }
}

A key with id example defined inline.

It’s recommended to define keys separately to customize name/lore/icon as needed, but this example is included here for completion.

keys = [
    ["example", 1]
]

Category: Gameplay

Published on Sep 5, 2021

views

stars

watchers

total downloads

Licensed under MIT

Promoted Versions

Members