UVVillagers
Note from the author:
This was my first plugin, built for use on the survival server I run for a few friends. It's far from the robust village infrastructure I originally envisioned, mainly because I didn't want to completely rewrite all of the core minecraft village code and villager behavior... but I think it accomplishes enough. Since it reached a point that I'm fairly happy with several months ago, most of the time the only updates I do are to address major bugs or bukkit upgrades.
This was also my first foray into Java. As such, the code can be a bit of a mess in places. If you want to poke around to see how I did what I did, or fork it and add functionality (or fix bugs!) check out the git repository on GitHub. You might have to poke me extra hard with pull requests merging functionality back in unless I'm expecting them. And hey, if you've looked at the code and aren't completely turned off by it, a co-maintainer would be welcomed to the project. I'm sure some of my users would appreciate your contributions! ;)
- James
The Goal
To make NPC Villages (and the expansion and defense thereof) a more integral part of the game.
Installation and Documentation
https://github.com/jcornwellshiel/uvvillagers/wiki - Lots of details here, and it's almost up to date! Go go go!
Important note on bukkit versions:
This plugin hits core minecraft classes, and thus can be only run on the appropriate bukkit versions. You can't use UVVillagers for CB1.6.4 on a 1.7.2 server, or vice versa. Starting January 2014, if there is not a recommended build for the latest minor bukkit version (for example, at the time of this writing, 1.7 only has dev, alpha, and beta builds available) I will publish two copies of this plugin for each update I do:
- One for the current Recommended Build (Currently 1.6.4-R2.0)
- One for the most stable recent build (currently Beta 1.7.2-R0.2).
If you need more than this, feel free to contact me.
Basic Features
- Player popularity tracking with villages.
- Greeting displayed on entering villages.
- Receive daily tributes from villages that you maintain and defend, based on population and popularity.
- Extra-awesome zombie sieges.
- Rewards for defending villagers from zombie sieges.
Details
- Villages: Villages expand the core minecraft NPC Village functionality to include:
- Villages are named after the first player to discover them (after installing the plugin), and can be renamed by whomever is most popular with the village.
- Per-village-per-player reputation, broken down into configurable tiers.
- Information about physical size, population, etc is reported to users.
- Notifications are displayed upon entering a village, a village being abandoned, etc.
- Commands to get information about villages are accessible via /uvv
- Villages will pay nearby players a configurable daily tribute every day at dawn based on the players' reputation and the village's population.
- Sieges: Zombie Sieges expand on the core minecraft Zombie Siege functionality, and are strongly enhanced and configurable.
- Any mob can potentially spawn. Yes, including withers and ender dragons.
- Siege statistics are tracked, and killing mobs that are part of a siege grants reputation with the village under siege.
Currently working: (version 1.3.8)
- Citizens support
- Configuration files! (All values and % chances can be changed!)
- Configurable messages!
- Village population and reputation announced upon nearing a village.
- Zombie Sieges can spawn all sorts of crazy stuff.
- Override core Zombie Siege mechanic in favor of ours.
- Spawn a siege on-demand.
- Village-Player reputation tracking
- Villager tributes! (Player receiving tribute must be near the village at exactly dawn)
- 0-3 emerald tribute per 20 villagers in nearby villages every day at dawn.
- 1 emerald tribute bonus per 20 villagers.
- 1-2 emerald tribute bonus per zombie siege kill during the previous night.
- multiplier based on current reputation
- Dynmap support is now integrated
- Multiworld support
- Some prevention of typical zombie siege avoidance tactics (like using floating platforms) by spreading spawns out over a radius.
- Can now select items other than emeralds for tribute!
- Collecting tribute from a mayor instead of it magically appearing (requires CB 1.5.1)
- Set whether tribute is collected from the Mayor or appears directly in your inventory
- Configurable minimum village size
- Preventing villager purchases if your reputation is too low
- Iron Golem aggro on extremely low reputation
- Overriding core popularity effects (cancel iron golem attack if it's caused by your reputation being too low)
- Chest tribute
- Better mayor retention
- Server-owned villages with /uvv setserver
Known Bugs
- Null exception thrown for some people using dynmap (properly caught since 1.2.5, still not sure of root cause... for some people dynmap is returning null when creating new markers, even though the marker is created)
- Mayors sometimes teleport into occupied blocks, suffocating them. This might be addressed now.
Enjoy! Post your bugs, exploitable aspects, and suggestions in comments here or at the GitHub repo !
@kreezxil
Looking into it.
@diannetea
Currently the following permissions exist: https://github.com/jcornwellshiel/uvvillagers/wiki/Permissions
Additionally, only the top reputation player in a village can rename a village. I could potentially rework this so that anyone of a certain reputation rank could rename a village.
If you're using Citizens (or any other plugin that adds player-like mobs to the game), I haven't had time to work out the issue of villages being deleted when a real player isn't nearby, but a fake one is.
I would love to see some sort of permissions to who can name villages and such
This also seems to "delete" any villages on my server when the chunk unloads. I'm using Spigot so I don't know if it's Spigot specific or if I have something else conflicting.
Getting severe error see http://pastebin.com/vWp5ShTM
@stiefellak
What do you mean by restoring a village?
Minecraft defines a village as at least one villager and at least one wooden door. If a village was destroyed, that generally means it ran out of villagers. You'll have to put doors back up and cart some villagers back in via minecart or boat (or "cheat" using spawn eggs).
If the villagers/doors are still there but UVVillagers isn't recognizing a village there, I'll need more information.
How can I restore a village?
@Poleatar
Place an item frame near a villager, and place an emerald in it. The nearest villager will be renamed to Mayor of <villagename> and try to stay near the sign.
How do I set a mayor of a village?
Only barely minimally tested, but here's an official version compiled for 1.5.2.
http://functionnull.net/UVVillagers-1.2.3.jar
@Northcodedotno
Thanks. Will do later today.
Took too long or me :P I updated it myself If someone else wants it here it is: Link Removed: http://www.mediafire.com/?ep2rrllcpvpbmdr
All credits go to jcornswellshiel! I only changed some code to make this compatible.
Edit: jcornswellshiel I sent you a pull request if you want to merge :)
Can you update it to 1.5.2. When I was testing 1.2.2 it didn't work...
@Northcodedotno
Ditch the UVDynmap plugin - I've integrated that functionality directly into UVVillagers.
After reloading my server this showed up:
@bubblybill
I do need to address spawn for all of the larger mobs. Currently it picks a random point in the village to siege. Each mob then spawns at random coordinates within a configurable radius around that spot. It checks to see if those coordinates are empty first, and if occupied, it finds the highest empty block at that X,Z (using a built-in minecraft method known to act oddly sometimes) and spawns there instead.
Flying mobs don't start any higher than others at the moment.
I'll be modifying all that to a more comprehensive valid spawn location checker soon.
After alot of testing with my base plugins and not the ones with known issuse, Everything is working great.
There was only one little problem .. A Ghast managed to spawn in wall of my town hall (A three storey, happy house of mine carted villagers), Dont worry we killed it and all is good !
Just wondered if the mobs spawn close to the villagers or the village and do ariel mobs have an "X" amount above ground coordinate when spawning (Or was my Ghast (Now referred to as "Ian") just a one off).
@dtmullican
There's a known incompatibility with Citizens at the moment that I'll be working to address soon. (Basically, in my "does the minecraft village still exist" checks, I check to see if a player is near the village. Citizens uses player objects for at least some of its NPC types, but the server doesn't behave the same around them as it does around real players).
@Deth_Glitch
A few questions - What version of UVVillagers are you using? What other plugins are you using? Is there any console output when you approach a village?
Hmm...every time I'm away from my village for a bit, it gets renamed automatically.
Also, would it be possible to add Citizens2 Sentry support where the owner of a sentry gets credit for the kills?
Thanks for the great work.
No matter howmany villages I find they are refusing to notice them. Even making my own doesn't work. The min villager count is set to one but some villages are over 20
@CorvusPVP
Based on last night's shenanigans I'll assume you weren't using 1.2.0 yet (since 1.2.0 broke potions completely -_-).
Upgrading to 1.2.1 will resolve your issue of invincible potion-buffed mobs.