when adding custom trades to a villager with no profession and no trades using /data modify, when he is clicked, the gui appears and closes instantly, the trade is there because the villager will have the item holding behavior and if there is a lag spike during the click, the gui might be visible for a second
exact command:
/data modify entity (villager) Offers.Recipes append value {maxUses: 10000, buyB: {id: "minecraft:stone", Count: 1b}, buy: {id: "minecraft:stone", Count: 1b}, sell: {id: "minecraft:stone", Count: 1b}, xp: 0, uses: 0, specialPrice: 0, rewardExp: 0b}
this only affects villagers without a profession and with AI
/summon villager ~ ~ ~ {VillagerData:{profession:"minecraft:none"},Offers:{Recipes:[{maxUses:100,buyB:{id:stone,Count:1b},buy:{id:stone,Count:1b},sell:{id:stone,Count:1b}}]}}
- is duplicated by
-
MC-169803 Villager Trading Window Closes Immediately When Opened
- Resolved
-
MC-236055 spawning villagers using summon with a custom trade and interacting with them will make the trade to appear then disapper
- Resolved
- relates to
-
MC-274445 Opening your inventory when riding some mobs while continuously modifying its data will make the GUI flash
- Resolved