VZone Plugins/VVoucher/Configurations/vouchers/example.yml

Config

example.yml
# ============================================================
# VVoucher example voucher file
# ============================================================
#
# You can create as many .yml files as you want inside:
# /plugins/VVoucher/vouchers/
#
# Every top-level key is a voucher id.
# Example:
#   fly-permission:
#   money:
#   rank-voucher:
#
# The voucher id is used by:
# - /vvoucher give <voucher-name>
# - the internal NamespacedKey marker: vvouchers:%config-key%
#
# Important:
# Items created by this plugin do NOT keep their normal vanilla behavior.
#
# ============================================================
# Supported click actions
# ============================================================
# - RIGHT CLICK
# - LEFT CLICK
# - MIDDLE CLICK
# - SHIFT + RIGHT CLICK
# - SHIFT + LEFT CLICK
# - SHIFT + MIDDLE CLICK
# - HAND SWITCH
# - SHIFT + HAND SWITCH
#
# ============================================================
# Optional settings inside a voucher
# ============================================================
# Material:
#   Bukkit material name. Example: PAPER, FEATHER, DIAMOND
#   You can also use:
#   - HDB-12345
#
# Name:
#   Display name of the item.
#
# Texture:
#   Optional. Only works if Material is PLAYER_HEAD.
#
# Lore:
#   List of lore lines.
#
# Unbreakable:
#   true / false
#
# CustomModelData:
#   Set to -1 to disable.
#
# TooltipStyle:
#   Optional.
#   Only works on Minecraft 1.21.2 or newer.
#   Sets the minecraft:tooltip_style data component on the voucher item.
#   Format: namespace:path
#   Example: global:mythic
#   Resource pack textures:
#   - assets/<namespace>/textures/gui/sprites/tooltip/<path>_background.png
#   - assets/<namespace>/textures/gui/sprites/tooltip/<path>_frame.png
#   Invalid values are skipped with a console warning.
#   Older server versions ignore this option.
#
# MaxStackSize:
#   Optional.
#   Sets the max stack size on the voucher item itself.
#   Use -1 or leave it out to disable it.
#
# Glow, Usage, Enable, Action, Command
# Message-Chat, Message-Title, Message-ActionBar
# Random-Command, Event, Random, Attributes, Enchantments, ItemFlags, Potion

fly-permission:
  Material: FEATHER
  Name: "<gradient:#1378FF:#60BFFB>Fly Permission</gradient>"
  Unbreakable: false
  Enable: true
  CustomModelData: -1
  Glow: true
  Lore:
    - ""
    - "&#1378FFINFORMATIONS"
    - "  &8&l| &fUsage: &#60BFFB%current-usage%&8/&#60BFFB%max-usage%"
    - "  &8&l| &fDuration: &#60BFFB1 hours"
    - ""
    - "&#1378FF> SHIFT + RIGHT CLICK TO USE <"
  Usage: 2
  Action: "SHIFT + RIGHT CLICK"
  Command: "lp user %player% permission settemp essentials.fly true 1h accumulate"
  ItemFlags:
    - HIDE_ATTRIBUTES
    - HIDE_UNBREAKABLE

money:
  Material: BOOK
  Name: "<gradient:#1378FF:#60BFFB>Money Voucher</gradient>"
  Enable: true
  Usage: 1
  Action: "SHIFT + RIGHT CLICK"
  Random:
    Min: 20000
    Max: 50000
  Command: "eco give %player% %random-amount%"
  Unbreakable: false
  CustomModelData: -1
  TooltipStyle: global:mythic
  Lore:
    - ""
    - "&#1378FFINFORMATIONS"
    - "  &8&l| &fUsage: &#60BFFB%current-usage%&8/&#60BFFB%max-usage%"
    - "  &8&l| &fMoney: &#60BFFB20,000-50,000"
    - ""
    - "&#1378FF> SHIFT + RIGHT CLICK TO USE <"
  ItemFlags:
    - HIDE_ATTRIBUTES
    - HIDE_UNBREAKABLE

hdb-head-example:
  Material: HDB-13376
  Name: "<gradient:#1378FF:#60BFFB>HDB Voucher</gradient>"
  Usage: 1
  Action: "SHIFT + RIGHT CLICK"
  Message-Chat: "{prefix} HeadDatabase voucher opened."

texture-head-example:
  Material: PLAYER_HEAD
  Texture: "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNzRlOGZmMzBlMzkzNzA5ODYzN2MwYWYwM2ExZjJhNmIxN2YwZTgyOGFiMmE1N2EyNjdhMDFkYTQ4NGJhMGM1NyJ9fX0="
  Name: "<gradient:#1378FF:#60BFFB>Texture Voucher</gradient>"
  Usage: 1
  Action: "SHIFT + RIGHT CLICK"
  Message-Chat: "{prefix} Texture head voucher opened."

random-permission:
  Material: ANVIL
  Name: "<gradient:#1378FF:#60BFFB>Random Permission</gradient>"
  Unbreakable: false
  Enable: true
  CustomModelData: -1
  Glow: true
  Message-Chat: "{prefix} Nyitottál egy random permissiont."
  Message-Title:
    Title: "&#1378FFRandom Permission"
    SubTitle: "&7Sok szerencsét!"
  Message-ActionBar: "{prefix}&7Megnyitottad a random permission voucheredet."
  Lore:
    - ""
    - "&#1378FFINFORMATIONS"
    - "  &8&l| &fUsage: &#60BFFB%current-usage%&8/&#60BFFB%max-usage%"
    - "  &8&l| &fDuration: &#60BFFB1 hours"
    - ""
    - "&#1378FF> SHIFT + RIGHT CLICK TO USE <"
  Usage: 2
  Action: "SHIFT + RIGHT CLICK"
  Random:
    Min: 20000
    Max: 50000
  Random-Command:
    Command1:
      Chance: 20
      Command: "lp user %player% permission settemp essentials.fly true %local-random%h"
      Message-Chat: "{prefix} You got a &#1378FFFly &7permission!"
      Message-Title:
        Title: "&#1378FFFly"
        SubTitle: "&7Duration: &#1378FF%local-random%h"
      Message-ActionBar: "&7Reward: &#1378FFFly"
      Random:
        Min: 1
        Max: 3
    Command2:
      Chance: 20
      Command: "lp user %player% permission settemp essentials.repair true 1h"
      Message-Chat: "{prefix} You got a &#1378FFRepair &7permission!"
    Command3:
      Chance: 50
      Command: "lp user %player% permission settemp essentials.god true 1h"
      Message-Chat: "{prefix} You got a &#1378FFGod &7permission!"
    Command4:
      Chance: 40
      Command: "lp user %player% permission settemp essentials.afk true 1h"
      Message-Chat: "{prefix} You got an &#1378FFAFK &7permission!"
  ItemFlags:
    - HIDE_ATTRIBUTES
    - HIDE_UNBREAKABLE

event-example:
  Material: IRON_INGOT
  Name: "<gradient:#1378FF:#60BFFB>Event Example Voucher</gradient>"
  Usage: 1
  Action: "SHIFT + RIGHT CLICK"
  MaxStackSize: 64
  Random-Command:
    Command1:
      Chance: 50
      Message-Chat: "{prefix} You got nothing!"
    Command2:
      Chance: 50
      Event: "example-event"