Crates Configuration File - Phoenix-Plugins/phoenix-crates-wiki GitHub Wiki
It is possible to configure the crates from the configuration file. You can view an example crates configuration file here to also help you.
Each crate have their own file inside crates folder. Check the default structure of a crate:
enabled: true
identifier: example1
display-name: '&eExample #1'
block-material: CHEST
engine: VANILLA_BLOCK
open-money-cost: 0.0
open-cooldown: 0
permission:
required: false
permission: phoenixcrates.crate.example1
animation:
idle-effects:
- DEFAULT;{REDSTONE;#ff0000;0.0;0.0;0.0;1.0;0.1;2}
- DEFAULT;{FLAME;#ffffff;0.0;0.0;0.0;2.0;0.1;2}
- STAR;{SMOKE_NORMAL;#ffffff;0.0;0.0;0.0;0.0;0.1;2}
opening-phases:
- CRACK;{}
- COMPACT;{#ffffff}
- HELIX;{}
hologram:
- '&e&l%name% Crate'
- ''
- '&7Right-Click to open!'
- '&7Left-Click to preview!'
preview-menu: default_rewards_preview
key:
enabled: true
item:
==: org.bukkit.inventory.ItemStack
v: 2975
type: TRIPWIRE_HOOK
meta:
==: ItemMeta
meta-type: UNSPECIFIC
display-name: '{"extra":[{"text":"&aExample #1 Crate Key"}],"text":""}'
lore:
- '{"extra":[{"text":"&7This is a lore line"}],"text":""}'
- '{"text":""}'
- '{"extra":[{"text":"&eUse this key in &6%crate%&e!"}],"text":""}'
rewards:
'0':
identifier: reward_1670612036361
item:
==: org.bukkit.inventory.ItemStack
v: 2975
type: DIRT
display-name: §7Dirt
percentage: 100.0
virtual: false
broadcast: false
commands: []
win-limits: -1
blacklist-permissions: []
alternative-reward:
enabled: false
reward:
item:
==: org.bukkit.inventory.ItemStack
v: 2975
type: DIAMOND_PICKAXE
display-name: §aAlternative Item
virtual: false
broadcast: false
commands: []
Below you can also see the meaning of each field:
-
enabled - This field has the function of activating and deactivating a create, so if it is disabled, no crate of this type will be available for the players.
-
display-name - This field has the function of naming this crate that will be used to represent the crate (e.g. will change the hologram name).
-
block-material - This field will define the block material itself for all crates of this type. Usually the common is a normal chest or an end chest.
-
engine - This field will define what engine this crate will use to be displayed to the world. Currently the options available are VANILLA_BLOCK, VANILLA_MODEL and MODEL_ENGINE.
-
open-money-cost - This field will define how much will cost for the player to open this crate.
-
open-cooldown - This field will define what cooldown that the player will have to wait to open again.
-
permission - This group of fields will define wheiter the player will need a permission to open this crate.
-
animation.idle-effets - This field will define what are the effects of the idle animation following pattern respectively:
Particle name, Particle hex color, Offset x, Offset y, Offset z, Radius, Effect type, Amount of particles.
-
animation.opening-phases - This field will define what are the phases of the opening animation following pattern respectively:
Phase Type, Phase Data
-
hologram - This field allows you to configure the lines of this hologram.
-
preview-menu - This field will define what is the menu that will be shown when the player left click the crate.
-
key - This group has a set of fields responsible for naming the name, lore and material type of the key. It is also possible to use one placeholders: {crate}.
-
rewards - This group has a list of sections responsible to keep the rewards of this crate.