Market

Enable Feature:

  • enable: true This toggles whether the entire feature is enabled or disabled.

enable: true

Container Title:

  • title: '<gradient:#A52A2A:#800000:#A52A2A>Fish Market</gradient>' This specifies the title of the container. The title "Fish Market" is displayed with a gradient color effect transitioning between three given hex color codes.

title: '<gradient:#A52A2A:#800000:#A52A2A>Fish Market</gradient>'

Limitation:

  • limitation: This section defines the limitations related to earnings from the fish market.

    • enable: true means the limitation feature is turned on.

    • earnings: 10000 specifies a cap on earnings at 10,000 units.

limitation:
  enable: true
  earnings: 10000
  # Support expression and placeholders
  earnings: '1000 + 50 * {level}'

Market Menu Layout:

  • layout: The layout section determines the visual arrangement of items/icons within the market menu. The symbols 'A', 'I', and 'B' reference specific items or icons.

layout:
  - 'AAAAAAAAA'
  - 'AIIIIIIIA'
  - 'AIIIIIIIA'
  - 'AIIIIIIIA'
  - 'AAAABAAAA'

Price Formula:

  • price-formula: '{base} + {bonus} * {size}' This provides a formula to calculate the price of loots from "CustomFishing".

price-formula: '{base} + {bonus} * {size}'

Item Price:

  • item-price: This segment assigns fixed prices to items. For instance, the "COD" is priced at 10 units. Additionally, items with a CustomModelData like "PAPER" with data "999" is priced at 5 units.

item-price:
  COD: 10
  PUFFERFISH: 10
  SALMON: 10
  TROPICAL_FISH: 10
  PAPER:999: 5

Item Slot:

  • item-slot: Dictates the slot where items (symbolized as 'I') to sell are placed. Items without an assigned price can still be placed if allow-items-with-no-price is set to true.

item-slot:
  symbol: 'I'
  allow-items-with-no-price: true

Dynamic Icons: (sell-icons / sell-all-icons) This section manages interactive icons. Icons here have multiple functions:

  • allow-icon: Indicates permitted trades.

  • deny-icon: Represents denied trades due to a lack of items to sell.

  • limit-icon: Appears when the worth of items exceeds the daily earnable amount. Each icon is further configured with display settings and triggered actions, such as sounds, messages, or commands.

sell-icons:
  symbol: 'B'
  allow-icon:
    material: IRON_BLOCK
    display:
      name: '<#00CED1><b>● <!b>Ship the fish'
      lore:
        - '<font:uniform><gradient:#E6E6FA:#48D1CC:#E6E6FA>You will get <green>{money}$</green> by selling the fish</gradient></font>'
        - '<dark_gray>You can earn {rest}'
    action:
      sound_action:
        type: sound
        value:
          key: 'minecraft:block.amethyst_block.place'
          source: 'player'
          volume: 1
          pitch: 1
      message_action:
        type: message
        value: 'You earned {money}$ by selling the fish! You can still get {rest}$ from market today'
      command_action:
        type: command
        value: 'money give {player} {money}'
  deny-icon:
    material: REDSTONE_BLOCK
    display:
      name: '<red><b>● <!b>Denied trade'
      lore:
        - '<font:uniform><gradient:#E6E6FA:red:#E6E6FA>Nothing to sell!</gradient></font>'
    action:
      sound_action:
        type: sound
        value:
          key: 'minecraft:entity.villager.no'
          source: 'player'
          volume: 1
          pitch: 1
  limit-icon:
    material: REDSTONE_BLOCK
    display:
      name: '<red><b>● <!b>Denied trade'
      lore:
        - '<font:uniform><gradient:#E6E6FA:red:#E6E6FA>The worth of items exceeds the money that can be earned for the rest of today!</gradient></font>'
    action:
      sound_action:
        type: sound
        value:
          key: 'minecraft:block.anvil.land'
          source: 'player'
          volume: 1
          pitch: 1

Decorative Icons:

  • decorative-icons: These icons are purely for visual enhancement. They do not possess functional attributes. In this case, a glass-pane is assigned symbol 'A', with the material being BLACK_STAINED_GLASS_PANE.

decorative-icons:
  glass-pane:
    symbol: 'A'
    material: BLACK_STAINED_GLASS_PANE
    display:
      name: ' '

Last updated