πŸ“‚ Crate Configuration File

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 has its file inside the crates folder. Check the default structure of a crate:

enabled: true
identifier: example4
display-name: '&eExample #4'
block-material: CHEST
engine: VANILLA_BLOCK
open-money-cost: 0.0
open-cooldown: 0
simultaneous-openings: false
preview-item: true
permission:
  required: true
  permission: phoenixcrates.crate.example4
animation:
  idle-effects:
  - DEFAULT;{ENCHANTMENT_TABLE;#ffffff;0.0;2.0;0.0;1.5;0.1;2}
  - DEFAULT;{FIREWORKS_SPARK;#ffffff;0.0;0.0;0.0;0.0;0.1;2}
  - CIRCLE;{SMOKE_NORMAL;#ffffff;0.0;0.0;0.0;0.0;0.0;2}
  opening-animations:
    '0':
    - DEFAULT;{}
    - SWIRL;{#ffffff}
    - FIRE_SPIRAL;{#ffffff}
hologram:
  lines:
  - '&e&l%name% Crate'
  - ''
  - '&7Right-Click to open!'
  - '&7Left-Click to preview!'
  - '&7Shift + Left-click to remove!'
  offset: 0.0
preview-menu: default_crate_reroll
key:
  enabled: true
  virtual: false
  glow: true
  item:
    ==: org.bukkit.inventory.ItemStack
    v: 3953
    type: TRIPWIRE_HOOK
    meta:
      ==: ItemMeta
      meta-type: UNSPECIFIC
      display-name: '{"text":"","extra":["&aExample #4 Crate Key"]}'
      lore:
      - '{"text":"","extra":["&7This is a lore line"]}'
      - '""'
      - '{"text":"","extra":["&eUse this key in &6%crate%&e!"]}'
max-win-rewards: 0
rewards:
  '0':
    identifier: reward_1718740580631
    display-item:
      ==: org.bukkit.inventory.ItemStack
      v: 3953
      type: DIRT
      meta:
        ==: ItemMeta
        meta-type: UNSPECIFIC
        display-name: '{"text":"","extra":[{"text":"Dirt","obfuscated":false,"italic":false,"underlined":false,"strikethrough":false,"color":"gray","bold":false}]}'
    win-items:
    - ==: org.bukkit.inventory.ItemStack
      v: 3953
      type: DIRT
    win-commands: []
    win-limits: -1
    percentage: 100.0
    broadcast: false
    restricted-permissions: []
    alternative-reward:
      enabled: false
      reward:
        item:
          ==: org.bukkit.inventory.ItemStack
          v: 3953
          type: DIAMOND_PICKAXE
        display-name: Β§aAlternative Item
        virtual: false
        broadcast: false
        commands: []
current-milestone: NOTSET
milestones: {}
reroll:
  enabled: false
  free-rolls: 0
  groups:
    '0':
      namespace: common
      rerolls: 3
    '1':
      namespace: rare
      rerolls: 5
    '2':
      namespace: legendary
      rerolls: 10
extra-settings:
  animation:
    display-item-position:
      x: 0.0
      y: 3.0
      z: 0.0

```

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 the player will have to wait to open again.

  • permission - This group of fields will define whether the player will need 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.

  • milestones - In this group, you will be able to set extra rewards when a user reaches a specific "goal"

  • reroll - In this group you will be able to define the amount of rerolls that the users can do.

  • display-item-position - With this setting, you can adjust the position of reward item.

Last updated