2

Villager with custom, restricted trades for adventure mode?

Starflyr3 11/4/19 7:14 pm
1.4k
11/6/2019 4:04 am
How do I get a villager to trade a custom, restricted item in adventure mode in vanilla 1.14.4?

I can summon the custom villager, and I can summon the custom item, but I cant figure out how to make the custom villager trade the custom item?

Specifically, an item with the CanPlaceOn modifier?

I can do this:

/summon villager ~74 ~22 ~13 {VillagerData:{profession:librarian,level:99,type:plains},Invulnerable:1,PersistenceRequired:1,CustomName:"\"Mayor Bob\"",Offers:{Recipes:[{buy:{id:bread,Count:3},sell:{id:lever,Count:1},rewardExp:0b,maxUses:1}]}}

and this:

/give @p minecraft:lever{display:{Name:"[\"text\":\"LEVER\"}]"",Lore:["{\"text\":\"Mine Key\"}"}],CanPlaceOn:minecraft:stone}

but..how do I make the villager give that lever? Help!

TIA!
Posted by
Starflyr3
Level 27 : Expert Dragonborn
4

  Have something to say?

JoinSign in

6

047Gaming
11/05/2019 1:12 am
Level 38 : Artisan Loremaster
I have literally no idea
2
Taruyroiii
11/05/2019 12:18 am
Level 66 : High Grandmaster Blob
You can use mcstacker.net to make the job easier. It generates commands for 1.14. You can also use XIsumavoid's custom villager shops data pack to create custom villager trades. But I recommend the mcstacker so you can summon the villager again and again.
4
HoboMaggot
11/05/2019 4:27 am
Level 55 : Grandmaster Blob
The link just incase: https://mcstacker.net/1.14.php
2
HoboMaggot
11/05/2019 12:07 am
Level 55 : Grandmaster Blob
Offers:{Recipes:[{sell:{id:"minecraft:lever",Count:1b,tag:{display:{Name:'{"text":"LEVER"}',Lore:['{"text":"Mine Key"}']}
3
Starflyr3
11/05/2019 9:15 am
Level 27 : Expert Dragonborn
OMG, THANK YOU Hobomaggot!!! This worked!

/summon villager ~ ~ ~ {VillagerData:{profession:PROFESSION,level:99,type:BIOME},Invulnerable:1,PersistenceRequired:1,CustomName:"\"NAME\"",Offers:{Recipes:[{buy:{id:bread,Count:3},sell:{id:";minecraft:lever";,Count:1b,tag:{display:{Name:'{"text"':"NAME"}';,Lore:[{"text":"LORE"}']} ,CanPlaceOn:["minecraft:stone"]},rewardExp:0b,maxUses:1}}]}}

PHEW!
2
HoboMaggot
11/06/2019 4:04 am
Level 55 : Grandmaster Blob
history
Just note, Ive had villagers reset their trades upon seeing another job site. If your villager's trades get reset, try putting down the profession job site block and then summon the villager. Or give the villager 1xp
2

Welcome