1

Villager Settings Adventure map

Raggebus 6/7/19 7:57 am history
291
6/8/2019 2:44 am
Hi!

So I'm new to settings with villagers in Adventure maps but I'd really like to learn how to use them for adventure maps.

So I have a couple of redstone related questions.
1. I would like to spawn a villager that can't:

Move

Take Damage

Trade



But I want it to be able to:

Have a custom name

Talk when you try to trade with him (right click him, and then a message comes up in chat)

Can take and give you items with custom names. For example: You right click the villager, he checks if you have a diamond named 1, if you have it, he gives you an emerald named 2. If you don't have the diamond he says "You don't have my diamond"



I know it's much to ask, but would really appreciate some help!

Thank you, minecrafters!
Posted by
Raggebus
Level 1 : New Miner
0

  Have something to say?

JoinSign in

7

ScotsMiser
06/08/2019 2:44 am
Level 71 : Legendary Miner
history
Setting the NoAI tag to true wil prevent movement.

Setting the Invulnerable: tag to true will prevent the mob form bieng damaged

From the description, you want the villager able to trade, but want to write very specific custom trades.
This would generally be done in the Offers: section of the entity data, but it is unclear whther the CustomName tag feature is accessible under offers.


EDIT: previous replies did not show until the page reloaded???
1
Heroder55
06/07/2019 8:09 am
Level 14 : Journeyman Cake
wan't? Do you mean want?
1
Raggebus
06/07/2019 8:48 am
Level 1 : New Miner
Yeah, fixed it. Thanks!
1
Heroder55
06/07/2019 9:33 am
Level 14 : Journeyman Cake
The first part:
No moving = NoAI set to 1
No damage = Invulnerable set to 1
No trade = Proffesion set to 0.

Custom name = CustomName

The other 2 made with datapack and click events.

Some online tools will probably help you.
1
HoboMaggot
06/08/2019 1:41 am
Level 55 : Grandmaster Blob
Actually to not trade, you can now put {Offers:{}} instead.
Also Custom name is now inputted like this {CustomName:"{\"text\":\"Villager\"}"}

This is assuming you have 1.14 btw
1
Raggebus
06/07/2019 10:32 am
Level 1 : New Miner
Ah, thanks. You know any good online tools for that?
1
Heroder55
06/07/2019 1:58 pm
Level 14 : Journeyman Cake
this site will help you in 50%. I don't know what to do with that click event, but apparently there is something for that.
1

Welcome