Minecraft Data Packs / Tool

Villager configurator

  • check_circle Functions
  • check_circle Predicates
  • 5,798 views, 2 today
  • 286 downloads, 0 today
  • 24
  • 17
  • 5
Ferr's Avatar Ferr
Level 43 : Master Engineer
19

Villagers configurator


This datapack is intended for mapmakers to help setting up the villagers.

What can it do?
- change the villager type (plains, snow, savana, etc)
- change the villager profession (nitwit, armorer, librarian, etc)
- change the villager level (novice, apprentice, master, etc)
- toggle the following flags: Invulnerable, NoAI, Silent

Why do i need it?
- probably most of you are just going to use an online generator to get a summon command and get the villager you want, with the appearence you want and so on.
  -> but let's say the next day you change your mind and decide that the villager you just added needs to be a different type, what do you do? kill it -> change the command -> summon a new one? that if you still have the command, otherwise you have to set again all the configurations and generate the command again...
  -> instead, you could use this to change the villager directly
- this cannot set the villager trades, but it could be used together with the datapack "custom villager shops" from vanilla tweaks https://vanillatweaks.net/picker/datapacks/ , however, be careful to have all the trades set before you move on to changing the villager's profession, cuz each time you use custom villager shops to set the trades, it changes him back to a nitwit.

How to install it?
- go to the folder of the map you want to add it to, and paste the zip file into the datapacks folder
- log in and run the command /reload
- everything should be set up and ready to be used.

How to use it?
- just get a debug stick
/give @s minecraft:debug_stick- then smack the villager with the stick to cycle thru the different professions
- if you want to change what the stick does hold shift and hit the villager (with the stick), it will cycle thru the different modes [​type, profession, level, Invincible, noAI, silent] then hiting it without shift will cycle thru the different states of the mode you've chosen
- hiting the villager with the debug stick will also heal him so you don't have to worry about killing him (except if you have something like strength 100 and you just 1 shot him ofcourse)

I'm done with the map, how do i uninstall it?
- run the uninstall function as follows:/function villagers_config:uninstall- if this gives a green successful message everything is ok and the datapack is disabled
- if it gives a red message it means that the scoreboards have been removed, but something went wrong with disabling the datapack (most likely the name of the .zip file is not the same) In this case you will have to disable it manually using the following command:/datapack disable "file name between quotes"- shouldn't be too hard to find the correct name, since now minecraft is giving you sugestions of the valid ones.



Feel free to leave sugestions and report bugs in the comments below.
CompatibilityMinecraft 1.16
toMinecraft 1.17
Tags

Create an account or sign in to comment.

1
09/18/2020 11:01 pm
Level 1 : New Miner
Spongebobfan907
Spongebobfan907's Avatar
you do realize that smacking the villager with the debug stick will decrease your reputation on that village
3
10/04/2020 11:01 am
Level 43 : Master Engineer
Ferr
Ferr's Avatar
well, it's only ment to be used for mapmaking.. (and maybe creative building) where you will mostlikely have custom trades set for the villagers anyways, so the reputation will have no impact... or no trades at all and they might just be there as part of the decoration...
1
08/25/2020 6:48 am
Level 58 : Grandmaster Miner
WandererReece
WandererReece's Avatar
I gotta try this sometime. This deserves a netherite ingot!
1
08/24/2020 9:19 am
Level 1 : New Crafter
Scrooge McDuck
Scrooge McDuck's Avatar
I like it, but change it so you right click. I nearly killed a villager!
Anyways, great DataPack!
1
08/25/2020 11:06 am
Level 43 : Master Engineer
Ferr
Ferr's Avatar
you shouldn't be able to kill it (unless you have strength effect or a stick that can 1hit kill it), hitting it with the stick will also heal up the villager, and i chose to do it this way for 2 reasons:
1. it's more fun :D
2. if the villager already has some trades set when you are changing his aspect, it will open the trades as well when you right click him.
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome