LegendaryDailyShop
  • 💎插件文档
  • 🚧须知
  • 📨插件介绍
  • ⚙️插件安装
  • 📒插件配置
    • 📃config.yml
    • 📃rarities.yml
    • 🛒商店配置
    • 📖商店界面模板
    • 🪙自定义商品货币
      • 自定义物品类型货币
      • 使用其他经济类插件
    • 🛍️创建商店
  • 🏴󠁧󠁢󠁳󠁣󠁴󠁿插件命令 & 权限
  • ✍️插件变量
  • 更新记录
Powered by GitBook
On this page
  1. 插件配置

商店界面模板

每个模板即为一个商店界面,你可以创建多个商店界面的模板应用到不同的商店内。达到自定义不同商店的界面。

Previous商店配置Next自定义商品货币

Last updated 11 months ago

配置文件位于 Templates 文件夹下

每个模板的配置节点如下

Default.yml
title: '%shop%'
size: 54
#商品出现的位置  & The slot where the product appears
#这里设置了多少位置,则该商店每日刷新多少商品 & How many slot are set here, how many products are refreshed by the store every day
layout: [11,13,15,29,31,33]
#当该商品位没被随机到商品时展示的物品 & Items displayed when the item is not randomly assigned to the item
empty:
  display: '&f[ &e无商品 &f]'
  material: BARRIER
  data: 0
  amount: 1
  model: 0
  lore:
    - ''
    - '&f该位置每有随机到商品'
    - '&f你的运气似乎不是很好...'
#商品的lore模板 %lore%为商品的原lore & The lore template% lore% of the product is the original lore of the product
items_lore:
  - '&7商品品质: &e%rarity%'
  - '%lore%'
  - ''
  - '%placeholder_sellOrBuy%'
  - '&e价格: &a%price%%currency%/个'
  - ''
  - '&a左键 &b购买/出售 &d1 &b个'
  - '&a右键 &b购买/出售 &d32 &b个'
  - '&aShift+左键/出售 &b自定义数量'
  - '&aShift+右键 &b出售 &d所有 &b个'
  - ''
  - '%placeholder_limit%'
  - '%placeholder_limit_self%'
#当你将随机池内某个物品删除但该玩家今日商店内还有该商品时展示的物品
# The item displayed when you delete an item from the random pool but the player still has the item in the store today
unknown:
  display: '&c商品已被下架'
  material: REDSTONE
  data: 0
  amount: 1
  lore:
    - ''
    - '&c该商品已被下架...'
    - ''
# 变量 & variable
placeholder:
  buy: '&e商品类型: &a购买'
  sell: '&e商品类型: &a出售'
  limit: '&e限量: &a%buy%/%max%'
  limit-self: '&c在全服限购的基础下你能购买 &e%buy%/%max% &c次'
  #当玩家有折扣时的价格变量%price%变为如下
  #%oldprice%为原价 %discount%为打折后的价格
  discount: '&a&m%oldprice%%discount%'
customItems:
  refresh:
    display: '&f[ &a点击刷新 &f]'
    amount: 1
    material: APPLE
    data: 0
    model: 0
    lore:
      - ''
      - '&f点击刷新 &e当前 &f商店.'
      - '&f你还有 &a%amount% &f点刷新次数.'
    slot: [49]
    fuction:
      # refresh 刷新按钮 &  Click to refresh the shop's products
      # null: 点击后不发生任何事情,属于装饰品 &  Nothing happens after clicking, it belongs to decoration
      # close: 点击后关闭GUI & Click to close GUI
      type: refresh

默认模板图片

创建新的界面模板并运用到指定商店

  1. 在 Templates 文件夹下新建一个yml文件 (文件名即为该模板的ID)

  2. 复制 Default.yml 并修改成你需要的排版

  3. 打开需要应用的商店配置文件

  4. 加入 template: 模板ID

  5. 重载插件

📒
📖