UsefulVillagers
RIP
Unfortunately, yeah, this plugin is dead. I've repeatedly said that I've no time left for it. The source are available but nobody's dare to maintain it, only complain that it doesn't evolve. Sorry internet, blame yourself for that. There's no charge for this plugin, I've never asked for donations. Now if you want to make it live (if it's worth it as "many other plugins are better" as i've read sometimes), use your brain, use your skills, use your own time. By now, I'm done.
Summary
This plug-in aims at adding some purpose to the villagers. Instead of walking around, villagers can also performs tasks depending on their profession. As they walk around, they will grow food, cut trees, gather sugar cane to make books, get wool, use furnaces, mine, etc.
Changelog for 0.4.0
- Added a configuration key in 'config.yml' that avoid 'not useful villagers' messages.
- Blacksmith now also cook pork (how strange it is ...).
- Various internal technical improvement.
Quote from Some Random GameDev:There's now a dependency to Gson. You'll have to download the third library jar, store it somewhere and update the -Djava.ext.dirs parameter.
Usage
First, a complete manual is available here.
Villagers professions can be set by right-clicking with the appropriate items:
- Wheat : Transforms a villager into a 'farmer'. A farmer will harvest wheat, melon and pumpkin, sugar cane.
- Book : Transforms a villager into a 'librarian'. Librarians take sugar cane from chest, use nearby workbench to produce books and put back produced books in the next encountered chest. Librarian can also 'study' weird items, such has glowstone dust, blaze powder, ghast tears, and give back experience points to players (study time depends on the given item).
- Iron ingot : Transforms a villager into a 'blacksmith'. Blacksmith with furnaces and chests in there surrounding will automatically transfer goods from furnace to chest and start smelting job from chest content. If interacted with a gold pickaxe, the blacksmith gain (or loose) mining ability (see manual for full description/usage).
- Leather : Transforms a villager into a simple 'butcher'. Butcher, for now, uses shear to collect wool from sheep.
- Glass Bottle : Transforms a villager into a 'priest'. Priest heal and defend villager (and player) with spells.
A villager can be provided with items by right-clicking on it.
- Give an hoe to a farmer and it will be able to transform dirt/grass to soil and plant seeds.
- Give seeds to a farmer to allow him planting seed.
- Give an axe to a farmer and it will be able to cut tree (if the tree is marked for cutting).
- Give sugar cane to librarian and it will craft books as soon as it cans.
- Give interesting stuff to librarian and it will study them and give back experience to you after time.
- Give shears to butcher and it will collect wool from sheep.
- Give stone or iron pickaxes to blacksmith and if it has a mining ability, it will mine below iron blocks.
- Give glowstone dust to priest and it will heal surrounding players and villagers.
- Give blaze rod to priest and it will set nearby monsters on fire (creepers/spider/skeleton/zombie).
(Extra : Give torches to a golem and it will place them in encountered dark places).
When a chest is encountered, the villagers will put their products in it (wheat, melon, pumpkin, wood logs, sugar cane, books, wool).
Disclaimer
It is not a 'active AI'. It is not experimental and rely totally on bukkit API. Hence, this plugin doesn't override villager behaviour but add some features to it. The villagers will continue to move and act as they're used to. But, periodically, player-activated villagers will modify their environment accordingly to their profession.
Roadmap
- Add priest brewing capabilities.
- Add more flexible serialization (XML or other) to allow easy migration without blasting all !
- Add blacksmith charcoal production management.
- Add butcher management (animals breeding and processing).
- Add commands for live administration.
Any suggestions are welcome.
Rejected Suggestions
First of all, keep in mind that I can't alter villagers movement.
- Fishing : Heart breaking, but it's not possible ...
- Villager self-defense : out of my range (only passive area of effet enabled via priest).
- Structure building
Commands
None for the moment. See Roadmap.
Configuration and Permissions
Again, a complete manual is available here with details concerning configuration and permissions. Check this out and read it !
Requests
Don't hesitate to report any problems or make any suggestions here.
@SomeRandomGameDev
awesome :D
Hi everybody ! Thank you for your kind words. I'm really sorry for not being able to make some updates. I'm really really busy right now, and I'll try to work on this plugin as soon as I can. Again, feel free to fork and update this plugin to your needs.
sould you mind if i use some oy four idea to get Children in Marriage Reloded working for you?
ill put credits on the main page
This plugin is SUPER!!!!!!!!!!!!!!!!!
@tarkus80
I'll make it configurable for sure. Thank you for the feedback.
@SomeRandomGameDev
great plugin, but is it possible to disable the message "this is not a usefull villager" ? that conflicts with shopkeeper plugin :/
@dylanisawesome1
The problem with that kind of cood is that it will be obsolete as soon as the server dev team decide to cut the access to this "supposed to be" internal stuff, or even make a big rework of the engine. I always follow the rule saying that one shall only use declared interface and not inner implementation.
Altering villager movement: http://forums.bukkit.org/threads/tutorial-how-to-customize-the-behaviour-of-a-mob-or-entity.54547/ also, to create the fishing bobber visual effect, use this code: http://pastebin.com/nDKU70p4 that should work.
@diannetea
Sure, admin commands are planned. And this one could be useful (I admit that it's really painful to perform tests each time, using the creative mode, eggs, and so on ;p)
Okay it must be an issue with the WorldGuard area, that was the second assumption :)
Is it possible that I could have an admin command or setting to pre-"stock" the villagers I'm creating instead of having to mess around in creative mode to add items to every one I create? Especially iron golems, I'd love if I could just give them a full stack of torches.
@diannetea
They do. They harvest sugar cane and can even plant them is there's the appropriate marker below their dirt/sand block.
Can the farmers pick up the sugar cane like they do with other things?
I am not terribly good at making logos, but I am going to attempt to make a video showcasing the plugin!
I'm thinking about making a neat logo for this plugin. But I'm out of imagination when it comes to represent a useful villager as a pictogram ... If some of you have an idea, it will be warmly welcomed !
(ouch, that doesn't sound english at all ... sorry guys ;p).
@WarmakerT
You're a monster :D
@diannetea
I'm extremely sorry, but that sounded so wrong.
@SomeRandomGameDev
I would love to, unfortunately I know no Java and spend most of the time trying to make the server great so my mom can have fun with her friends :)
@diannetea
Aaaaand fixed. I've made some testing. It should work by now. Well, nobody's perfect, and there will probably have some other bugs.
Again, check the github. Do as GUIpsp kindly does ! Contribute to the plugin's code !
@diannetea
Ok, I see where the problem is. My plug-in chooses whether or not a villager should interact the "classic way". And if my plug-in comes after the shopkeepers one, I just overwrite the "isCanceled" flag of the event. Well, I'm not a home right now. Expect a correction in 8 to 9 hours, the time I go back to my place. My apologies for the inconvenience.
Butcher breeding and slaughter is in my think-pipe. I'm trying to figure our the dynamic (chest with wheat ? Artificial breeding - as the API prevent us from setting animals to breeding behaviour - but things may have changed ...).
Edit : Busy week-end in fact ... I didn't have the time to correct nor to incorportate the pull request in github (thank you GUIpsp btw !). I'll try to sort this out this evening.
I use this with Shopkeepers and have villager trading OFF except for set up shops, and this plugin seems to be reverting that feature so now my villagers can be traded with again. It is also keeping me from setting up shops :(
Please fix :(
Also could butchers breed and slaughter animals?
@SomeRandomGameDev
haha! No problem! Sorry, I wish I could code myself more, otherwise I would have made the pull and request myself! GUI is on break and I don't really get to see him every day otherwise, heh. Thank you for including it!