Aller au contenu principal

Creating Treasure Chests

webapp_banner.jpg

Treasure Chests are a feature allows admins to make chests that can either drop loot or spawn a mimic (hostile) boss.

Values

isEnabled

Sets if a treasure chest is enabled.

KeyValuesDefault
isEnabledBooleantrue
Example
isEnabled: true

chestType

Sets the type of chest material.

KeyValuesDefault
chestTypeMaterialCHEST
Example
chestType: CHEST

This needs to be a valid chest material such as CHEST or BARREL.

create_chest_material.jpg


facing

Sets the facing direction of the chest.

KeyValuesDefault
facingSpecial [1]CHEST
Example
facing: CHEST

This needs to be a valid chest material such as CHEST or BARREL.

Special [1]

Expand Table
Facing
NORTH
SOUTH
WEST
EAST

dropStyle

Sets if the chest is meant to be dropped for one player or multiple players.

SINGLE chests disappear after being opened and reappear when restocked. GROUP chests stay around and let individual players know they're on cooldown.

KeyValuesDefault
dropStyleSINGLE / GROUPSINGLE
Example
dropStyle: SINGLE

lootList

Lists the loot that the treasure chest should drop when opened.

KeyValuesDefault
lootListEM Loot Tablenone
Example
lootList:
- filename=elite_scrap_tiny.yml:chance=0.90
- magmaguys_toothpick.yml

mimicChance

Sets the chance of spawning a hostile boss instead of dropping loot.

KeyValuesDefault
mimicChanceDouble0
Example
mimicChance: 0.5

mimicCustomBossesList

Specifies the list of hostile bosses available for spawning. A single boss will be randomly selected from this list for spawning.

The list also supports a weight system that you can implement to ensure some bosses are picked more often that the others.

KeyValuesDefault
mimicCustomBossesListString Listnone
Example
mimicCustomBossesList:
- my_cool_mimic_boss.yml
- weak_mimic_boss.yml

If you wish to assign weights to the bosses, the list should be formatted as follows:

mimicCustomBossesList:
- my_cool_mimic_boss.yml:60
- weak_mimic_boss.yml:40

In this configuration, my_cool_mimic_boss.yml is more likely to be chosen for spawning than weak_mimic_boss.yml.


restockTimer

Sets the time, in minutes, before the chest refills with loot.

KeyValuesDefault
restockTimerInteger0
Example
restockTimer: 30

effects

Sets the particle effects that the chest will do.

KeyValuesDefault
effectsParticlenone
Example
effects:
- DRIP_LAVA
- SMOKE_NORMAL

create_chest_effects.jpg


locations

Sets the locations where the treasure chest will spawn.

Locations can more easily be set through /em addTreasureChest <treasurechestfilename.yml>

KeyValuesDefault
locationsString Listnone
Example
locations:
- my_world,10,50,10,0,0
- my_nether_world,12,58,12,0,0

chestTier

Sets the minimum guild rank required to open the chest.

KeyValuesDefault
chestTierIntegernone
Example
chestTier: 3

instanced

Sets if the chest should be instanced (for use in instanced dungeons). All restock timers are disabled when chests are placed in dungeons.

DO NOT SET THIS VALUE MANUALLY.

KeyValuesDefault
instancedBooleanfalse
Example
instanced: true

restockTime

After a chest has been looted, the plugin will write this key to track restock time.

DO NOT SET THIS VALUE MANUALLY.

KeyValuesDefault
restockTimeUnix Timestampnone
Example
restockTime: 1707394380

Treasure Chest Config Example
isEnabled: true
chestType: CHEST
facing: NORTH
dropStyle: MULTIPLE
lootList:
- filename=elite_scrap_tiny.yml:chance=0.90
- magmaguys_toothpick.yml:chance=0.95
mimicChance: 0.50
mimicCustomBossesList:
- balrog.yml
- killer_rabbit_of_caerbannog.yml
restockTimer: 1
effects: SMOKE_NORMAL
locations:
- world,0.0,-60.0,-14.0,0.0,0.0

create_chest_chest.jpg