Content generated with AI — it may contain mistakes.

ExyliaEmotes/GuidesUpdated in v1.4.1

Set up the crate

Bind a block that opens the emote crate, give keys, set the odds of each rarity and sell emotes in the shop.

Page 8 of 218 min read
  

You end up with a crate that players open with a key to win emotes, owned for good whatever happens to their rank afterwards. A key is spent, a reel falls, and what it lands on is unlocked on the player's account. The crate engine is ExyliaLib's; ExyliaEmotes hands it the catalogue and reads its settings from config.yml and its lines from messages.yml.

Before you start#

Nothing else is needed: the crate is on by default (crate.enabled: true) and every player gets one key the first time they are seen. Ranks and money are covered in Permissions and ExyliaLib economy.

Steps#

Bind a block

Look at the block you want (up to six blocks away) and run /emotesadmin crate block add. Clicking it now opens the crate. You can also open the admin hub with /emotesadmin and use Crate blocks.

Give a key

Run /emotesadmin keys give <player> 1 to add a key to their account (works offline), or /emotesadmin item key <player> 1 to hand over a key item.

Open it

The player clicks the block, or runs /emote crate, or clicks Crate in the /emote menu. They pick Open 1, and the reel falls.

Check that it works#

Click the bound block with a key on your account. You should see the screen that asks how many to open (Open 1), then the reel falling and a chat line such as "You unboxed Rare WAVE". Run /emote list to see what you won. Left-clicking the block never spends a key.

Going further#

Keys on the account or in the hand#

The crate takes two kinds of key.

  • On the account is a number on the player's crate row. Nothing can be dropped, duped or lost to a full inventory. A shop, a vote listener or a reward plugin gives them from console: emotesadmin keys give %player% 1. Also keys take, keys set and keys check.
  • In the hand is an item (/emotesadmin item key <player> [1-64]), so it can be sold, put in a kit or given to a friend. Right-click a bound block holding one and it opens on the spot: one key, one reel, no question. Keys that do not fit in the inventory wait for the player's next join.

Every player starts with crate.start-keys keys, one by default.

Change the odds#

Each emote has a rarity, and tiers in config.yml declares the rarities. The shipped four are Common (60), Rare (25), Epic (12) and Legendary (3). The shipped catalogue has 29 common, 38 rare, 29 epic and 11 legendary emotes. chance is a weight, not a percentage: weights 60/25/12/3 behave exactly like 6/2.5/1.2/0.3, and deleting a rarity re-spreads its odds across the rest. You can rename them, delete one or invent mythic; an emote naming a rarity that no longer exists falls back to the first one and loses its colour, never its existence. See the tier keys in the details below.

Duplicates#

Landing on something already unlocked hands keys back, crate.duplicate-refund of them (one by default), so a duplicate is a free re-roll. An emote owned only through a permission is not a duplicate: it is unlocked for good, so it outlives the rank that granted it.

Opening in 3D#

With crate.opening: SPATIAL, the question screen stays but the opening is ExyliaLib's crate scene: a crate in the world, a reel slowing onto the prize, the lid opening, the prize with its rarity and whether it is new or a duplicate, and then the emote danced on a pedestal in the player's skin. After the last crate come OPEN ANOTHER (while they have a key) and DONE. Odds and key spending are exactly the same, sneaking skips to the end, and clients older than 1.21.4 always get the inventory reels. Its look is spatial/crate.yml.

The shop#

A locked emote can be bought from the menu. The row shows its price, a left click asks the player to confirm, and the menu comes back with the emote unlocked, the same unlock a crate writes.

config.yml
yaml
shop:
  enabled: true
  tier-prices:
    common: 500
    rare: 1500
    epic: 4000
    legendary: 10000

A price is a number (500, 2.5k) or {amount: 250, currency: gems}. An emote in emotes.yml can set its own price, which wins over its rarity's. A rarity left out of tier-prices is not for sale. The money is taken by ExyliaEconomy or Vault; with neither, or with the shop off, locked emotes look as they always have.

Hand emotes over without a crate#

/emotesadmin unlocks grant <player> <emote> and /emotesadmin unlocks revoke <player> <emote> write the same unlock a crate does, for a reward plugin or a support ticket. Keys and unlocks are account data, so a season wipe keeps them unless @account is named. To take everything from one player, run /exylialib resetplayer <player> ExyliaEmotes @account, see ExyliaLib's commands.

Permissions and unlocks are two separate ways in

A player may perform an emote they unlocked or one their rank grants. Selling a rarity as a rank is one line, exyliaemotes.tier.legendary, and it is independent of anything they unboxed.

Technical details: settings, tiers, blocks and the opening

Settings#

yaml
crate:
  enabled: true
  start-keys: 1
  duplicate-refund: 1
  reward: UNLOCK
  blocks: []
  max-at-once: 4
  spin-frames: 34
  stagger-seconds: 2.0
KeyDefaultWhat it does
enabledtrueOff, the crate says so instead of opening.
start-keys1Keys a player is given the first time they are seen.
duplicate-refund1Keys handed back for something already owned.
rewardUNLOCKUNLOCK, ITEM or BOTH. An emote has no item to hand over, so all three unlock: a key never buys nothing.
blocks[]The blocks that open the crate. Bind them in game, not by hand.
max-at-once4How many crates one player may open in one go. The screen fits seven.
spin-frames34How many faces the first reel runs through before it stops. Capped at 200, about eleven seconds.
stagger-seconds2.0How long after one reel stops the next one does. 0 stops them together.

on-spin, on-win and on-duplicate are full ExyliaLib effect blocks, see Configuration. The shop keys are shop.enabled (default true) and shop.tier-prices (500 / 1500 / 4000 / 10000).

Rarities#

yaml
tiers:
  common:
    name: "Common"
    material: GRAY_DYE
    color: "{muted}"
    chance: 60.0
    priority: 1
  rare:
    name: "Rare"
    material: LIGHT_BLUE_DYE
    color: "{info}"
    chance: 25.0
    priority: 2
  epic:
    name: "Epic"
    material: PINK_DYE
    color: "{accent}"
    chance: 12.0
    priority: 3
  legendary:
    name: "Legendary"
    material: ORANGE_DYE
    color: "{highlight}"
    chance: 3.0
    priority: 4
KeyWhat it does
nameWhat menus and placeholders call it.
materialThe item the rarity is drawn with.
colorThe colour its name and its emotes are written in, see Colours.
chanceHow often a crate lands on it, relative to the other rarities.
priorityWhere it sits in menus; lower comes first.

The opening in the inventory#

  1. How many: lang/<code>/menus/crate.yml. Choices are drawn up to crate.max-at-once, capped at seven, spread the way the reels will be. A choice the player cannot afford shows how many keys it is missing.
  2. The reels fall: lang/<code>/menus/crate_open.yml. One reel per crate, each finishing crate.stagger-seconds after the one before.
  3. What went past stays: nothing is cleared when a reel stops.
  4. Paid out as each reel lands: keys are spent and prizes decided before the first frame, each reel pays out as it stops with crate.on-win or crate.on-duplicate. Closing the window mid-fall costs nothing.
RefusalMessage key
crate.enabled is offcrate-disabled
Not enough keyscrate-no-keys (%amount% is the cost, %keys% what they hold)
Their last opening is still fallingcrate-busy
The catalogue is emptycrate-empty

crate-won names what came out (%emote% or %reward%) and its rarity (%tier%); crate-duplicate uses %refund%; rewards-claimed is told when waiting keys are handed over.

Key item and crate blocks#

The key item is drawn from key-item in config.yml (material and glow) and messages.yml (name and lore). It is recognised by what it carries in its data, not by name or material. Key items minted by versions that ran their own crate keep opening it.

Crate block commands: /emotesadmin crate block add, remove, list and clear confirm. Blocks are written to config.yml, not into the world, so a bound block survives a schematic paste and a rollback. While bound it cannot be broken, blown up or pushed, and clicking it no longer does what its material does.

Something missing on this page? Tell us on Discord