minecraft:economy_trade_table

Defines this entity's ability to trade with players.

Properties

PropertyTypeDefaultWhat it does
display_nameText""The entity localization key used for the trading UI display name.
tableText""Path to the trade table JSON that defines available offers.
new_screenBooleanfalseWhether this trader uses the newer trade screen implementation.
hero_demand_discountInteger-4Additional demand discount applied while the player has Hero of the Village.
cured_discountObject{"max": -20, "min": -25}Range of cured villager discounts applied to trade prices.
minInteger0
maxInteger0
max_cured_discountObject{"max": -20, "min": -25}Maximum allowed range for cured villager discounts.
minInteger0
maxInteger0
nearby_cured_discountInteger-20Nearby cured villager discount step applied by legacy pricing.
max_nearby_cured_discountInteger-200Most negative nearby cured villager discount allowed by legacy pricing.
persist_tradesBooleanfalseWhether generated offers are persisted with the actor save data.
convert_trades_economyBooleanfalseWhether legacy trade data is converted into economy trade data.
show_trade_screenBooleantrueWhether interacting with this trader opens the trade screen.
use_legacy_price_formulaBooleanfalseWhether legacy price calculations are used instead of the newer pricing formula.

Example from the game files

This is how vanilla Villager uses it in Minecraft Bedrock 1.26.60.5:

{
  "minecraft:economy_trade_table": {
    "cured_discount": [
      -25,
      -20
    ],
    "display_name": "entity.villager.cartographer",
    "max_cured_discount": [
      -25,
      -20
    ],
    "new_screen": true,
    "persist_trades": true,
    "table": "trading/economy_trades/cartographer_trades.json"
  }
}

Used by 2

Vanilla entities with minecraft:economy_trade_table in their definition:

Related components