Перейти до змісту

NightMarket - Limited, Rotating Shops

Рекомендовані відповіді

Опубліковано

NightMarket - Limited, Rotating Shops


Плагін, який забезпечує змінний магазин з обмеженим доступом до Minecraft. Підтримує Vault і має простий у використанні API розробника для інших плагінів.

/nightmarket : відкриває графічний інтерфейс NightMarket (дозвіл: nightmarket.use)
/nightmarket-admin reload : перезавантажує конфігурацію (дозвіл: nightmarket.admin)
/nightmarket-admin forcerotate <player>: Примусово обертає наданий магазин гравця (дозвіл: nightmarket.admin)
/nightmarket-admin debug: надає інформацію про налагодження плагіна (дозвіл: nightmarket.admin)

Конфиг:

#
# NightMarket v1.1.0 by byteful
#

# Attention! Support will not be given to those who have not purchased this plugin through SpigotMC/MC-Market.

# [-----------------------------------------------------------------------------------------------]
#
# Useful Links:
#   => https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/Material.html
#   => https://minecraft-heads.com/player-heads
#   => https://wiki.vg/images/b/bb/DoubleChest-slots.png
#
# With text/messages, color codes, hex codes, and PlaceholderAPI (in some instances) is supported.
#
# [-----------------------------------------------------------------------------------------------]

# Configuration for the data store used to store players' current shop rotation. Remote databases are supported for cross-server night markets.
# > Types:
#   - Remote Databases: (You will need to use one of these for cross-server night markets!)
#       => MySQL (remote relation-based database, may have connection/lag issues)
#
#       => MongoDB (remote document-based database, may have connection/lag issues)
#
#   - Local Databases: (These will only store player night markets on the current server!)
#       => JSON (human-readable text format, prone to corruption and error)
#
#       => SQLite (flatfile relation-based database that lives in the plugins' folder, fast and stable)
#
datastore:
  type: SQLite
  # Only required if type is set to MySQL!
  mysql:
    user: root
    password: password
    host: localhost
    port: 3306
    database: NightMarket
  # Only required if type is set to MongoDB!
  mongo:
    uri: mongodb://username:password@host:port
    database: NightMarket

# Configuration for other miscellaneous settings.
other:
  # Should the GUI close after buying an item?
  close_on_buy: true
  # Should an announcement be sent when shops have rotated?
  rotate_announcement: true
  # Should NightMarket check SpigotMC daily for updates?
  update: true
  # Should NightMarket set currency name placeholders to lowercase?
  lowercase_currency_names: false

# Configuration for all the items that this plugin chooses from. Items will be randomly selected for players' shops based on their rarity.
# > Higher the rarity, the more common.
# > Example item configuration:
#  ItemId:
#    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
#      name: "diamond sword" # The display name of the icon displayed in the shop.
#      lore:
#        - "hello" # The lore of the icon displayed in the shop.
#      material: DIAMOND_SWORD # The material of the icon displayed in the shop. This is not the item given to the player.
#    command: "/give {player} diamond_sword 1" # The command ran once the player successfully buys the item.
#    price:
#      currency: "VAULT" # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
#      amount: 6.9 # The actual amount of currency the item costs.
#
items:
  # This ID will be stored with player's current shop rotation so changing these can cause unexpected results. This ID cannot contain the character ',' as it is used in databases as a marker.
  ItemId:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bUpgrade Scroll' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 30'
      custom_model_data: 10018 # The custom model data of the icon. Only works on versions 1.14+
      material: PAPER # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:SCROLL -id:WEAPON_SCROLL_UP # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 5.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 30 # The actual amount of currency the item costs.
  ItemId1:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Sword' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 5'
      custom_model_data: 0 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_SWORD # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:SWORD -id:WOODEN_SWORD -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 5 # The actual amount of currency the item costs.
  ItemId2:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Dagger' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 5'
      custom_model_data: 10000 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_SWORD # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:DAGGER -id:WOODEN_DAGGER -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 5 # The actual amount of currency the item costs.
  ItemId3:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Staff' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 5'
      custom_model_data: 10001 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_SWORD # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:STAFF -id:WOODEN_STAFF -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 5 # The actual amount of currency the item costs.
  ItemId4:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Bow' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 5'
      custom_model_data: 10000 # The custom model data of the icon. Only works on versions 1.14+
      material: BOW # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:BOW -id:WOODEN_BOW -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 5 # The actual amount of currency the item costs.
  ItemId5:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Shield' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 5'
      custom_model_data: 10000 # The custom model data of the icon. Only works on versions 1.14+
      material: SHIELD # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:SHIELD -id:WOODEN_SHIELD -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 5 # The actual amount of currency the item costs.
  ItemId6:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Axe' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 0 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_AXE # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:TOOL -id:WOODEN_AXE -tier:COMMON # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.
  ItemId7:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Pickaxe' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 0 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_PICKAXE # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:TOOL -id:WOODEN_PICKAXE -tier:COMMON # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.
  ItemId8:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Shovel' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 0 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_SHOVEL # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:TOOL -id:WOODEN_SHOVEL -tier:COMMON # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.
  ItemId9:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Hoe' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 0 # The custom model data of the icon. Only works on versions 1.14+
      material: WOODEN_HOE # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:TOOL -id:WOODEN_HOE -tier:COMMON # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.
  ItemId10:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&bWooden Shears' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 10000 # The custom model data of the icon. Only works on versions 1.14+
      material: SHEARS # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:TOOL -id:WOODEN_PICKAXE -tier:COMMON # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.
  ItemId11:
    icon: # Configuration for the icon displayed in the shop, not the actual item given to the player. That is done via commands for flexibility.
      name: '&aLeather Helmet' # The display name of the icon displayed in the shop.
      lore: # The lore of the icon displayed in the shop.
        - '&7Click to buy!'
        - '&6Price: 7'
      custom_model_data: 10000 # The custom model data of the icon. Only works on versions 1.14+
      material: LEATHER_HELMET # The material of the icon displayed in the shop. This is not the item given to the player.
    # player_head: "Steve" # The player name or skull texture to put on a player head. This is not the item given to the player.
    command: /mi generate {player} -type:ARMOR -id:LEATHER_HELMET -tier:COMMON -matchlevel # The command ran once the player successfully buys the item. Placeholders: {player} - the player's name
    purchase_limit: 1 # 0 = infinite purchases, otherwise, players are limited to only purchasing the limited amount
    rarity: 90.0 # Higher the rarity value, the more common. This will act as a weight when randomly selecting items for shop rotations.
    price:
      currency: VAULT # Currency depends on hooked currency plugins. Vault is supported by default. Other plugins will require external hooks to work with this option.
      amount: 7 # The actual amount of currency the item costs.

# The schedule for the opening and closing of the night market. Times and dates depend on timezone configuration at the bottom of this file (or system if not configured).
access_schedule:
  dates:
  - start: 12/31/2022 12:00:00 AM
    end: 01/01/2023 12:00:00 AM
  - start: 02/05/2023 12:00:00 AM
    end: 02/10/2023 12:00:00 AM
  mode: TIMES
  times:
  - start: 03:00:00 AM
    end: 11:00:00 PM

# The schedule for rotating the items in each players' night market. Times and dates depend on timezone configuration at the bottom of this file (or system if not configured).
rotate_schedule:
  dates:
  - 12/31/2022 12:00:00 AM
  - 01/01/2023 12:00:00 AM
  mode: TIMES
  times:
  - 03:00:00 AM
  - 11:00:00 PM

# Settings for the GUI displayed when running /nightmarket
gui:
  background_icon:
    name: ' '
    lore:
    - ''
    material: PAPER # player_head instead of material also supported here.
  # Title of the GUI
  title: '&eDaily Shop'
  # Number of rows in the GUI
  rows: 3
  # The GUI slots that will be populated with the background_icon item.
  # You may use '-' to indicate to. EX: 1-24 means all slots from 1 to 24.
  background_slots:
  - 0-8
  - '9'
  - '17'
  - 18-26
  # The GUI slots that items will be placed in. [!] The number of slots here will determine the number of randomly-picked shop items. [!]
  # You may use '-' to indicate to. EX: 1-24 means all slots from 1 to 24.
  item_slots:
  - 10-16

# Timezones supported by Java.
#
#  EST - -05:00
#  HST - -10:00
#  MST - -07:00
#  ACT - Australia/Darwin
#  AET - Australia/Sydney
#  AGT - America/Argentina/Buenos_Aires
#  ART - Africa/Cairo
#  AST - America/Anchorage
#  BET - America/Sao_Paulo
#  BST - Asia/Dhaka
#  CAT - Africa/Harare
#  CNT - America/St_Johns
#  CST - America/Chicago
#  CTT - Asia/Shanghai
#  EAT - Africa/Addis_Ababa
#  ECT - Europe/Paris
#  IET - America/Indiana/Indianapolis
#  IST - Asia/Kolkata
#  JST - Asia/Tokyo
#  MIT - Pacific/Apia
#  NET - Asia/Yerevan
#  NST - Pacific/Auckland
#  PLT - Asia/Karachi
#  PNT - America/Phoenix
#  PRT - America/Puerto_Rico
#  PST - America/Los_Angeles
#  SST - Pacific/Guadalcanal
#  VST - Asia/Ho_Chi_Minh
#
# Numerical offsets can also be used. (-05:00)
#
# If blank, system timezone will be used. Use this only to override system timezone for access/rotate schedules.
#
# [!] UPDATING THIS VALUE WHILE THE SERVER IS ON WILL REQUIRE A RESTART FOR IT TO PROPERLY APPLY.
timezone: Asia/Tokyo

 


 

Приєднуйтесь до обговорення

Ви можете написати зараз та зареєструватися пізніше. Якщо у вас є обліковий запис, авторизуйтесь, щоб опублікувати від імені свого облікового запису.
Примітка: Ваш пост буде перевірено модератором, перш ніж стане видимим.

Гість
Відповісти на цю тему...