RandomEncounters
Overview
Tired of seeing the same old villages? Wish there was a way to add configurable encounters to the world? This is the problem Random Encounters aims to fix. From portal temples on the overworld with their Blaze leader and a horde of mad zombie pigmen gated in from the nether to common farms. Each encounter is configurable including the probability of the encounter, to the encounters eventual expansion, to the probability of each treasure item in chests or on the mobs.
Features
- Add encounters to the minecraft world
- Configure hostile mobs
- Configure encounter treasure
- Configure encounter growth
- No more are there just plain old villages
- Allows the placement of large structures without lagging the server
Dependencies
Configuration
Plugin Configuration
debug
The Debug section is designed to help developers in identifying how the plugin is operating to aid in-game verification and help troubleshoot the plugin during development.
- midas [Boolean] (default: false) King Midas was known for turning everything he touched into gold. This debug mode turns the surface area checked into gold to spot invalid encounter placement areas
- loglevel [Integer] (default: 0) This debug option tells the plugin how much information to output.
maxLockTime
[Integer] (default: 10) This is the maximum number of milliseconds any task will lock the server for processing.
structureConfig
The structureConfig option is a string of the file name containing the structure configurations in JSON format. The default value is structures.json.
{
"structures": [
{
"name": "(String) Unique structure name",
"file": "(String) Schematic file name including directories",
"minY": "(Integer) Minimum Y coordinate to place the structure",
"maxY": "(Integer) Maximum Y coordinate to place the structure",
"trump": [
"(String) MaterialName of over writable material",
],
"invalid": [
"(String) MaterialName of invalid foundation material",
]
},
],
}
mobConfig
The mobConfig option is a string of the file name containing the mob / creature configurations in JSON format. The default value is mobs.json.
For more information on the mobs.json visit:
Mob Configuration Options
treasureConfig
The treasureConfig option is a string of the file name containing the treasure / item configurations in JSON format. The default value is treasures.json.
{
"treasures":[
{
"name": "(Sring) Unique treasure name",
"material": "(String) MaterialName",
"tagName": "(String) Item Name",
"min": "(Integer) Minimum",
"max": "(Integer) Maximum",
"probability": "(Double) Probability",
"treasureGroups": [
{
"name": "(String) Treasure name for group",
"min": "(Integer) Minimum number to generate",
"max": "(Integer) Maximum number to generate",
"probability": "(Double) Probability of additional groups"
}
],
"enchantments": [
{
"enchantment": "(String) EnchantmentName",
"probability": "(Double) Probability",
"level": "(Integer) EnchantmentLevel"
},
]
},
],
}
encounterConfig
The encounterConfig option is a string of the file name containing the encounter configurations in JSON format. The default value is encounters.json. The encounter configuration file is what ties Structures, Mobs, and Treasure all together.
{
"encounters": [
{
"name": "(String) Unique Encounter Name",
"enabled": "(Boolean) should new encounters be generated",
"probability":"(Double) probability of occurrence",
"structure": "(String) Structure name from defined structures",
"mobs": [
"(String) Mob name from defined mobs",
],
"validBiomes": [
"(String) Biome name",
],
"invalidBiomes": [
"(String) Biome name",
],
"treasures": [
"(String) Treasure name from defined treasures",
],
"expansions": [
{
"encounter": "(String) defined Encounter name",
"probability": "(Double) probability of expansion",
"duration": "(Integer) Duration in minutes to check ",
"max": "(Integer) maximum number of expansions",
"distance": "(Integer) maximum distance in chunks"
},
]
},
]
}
Commands
re reload
Reloads the JSON configuration files. Keep an eye on the console for errors
re place <encounter> [<world> <x> <y> <z>]
Forces an encounter to be placed at the player's current location or the location specified. This does not perform terrain checks. The console command must specify the coordinates
re check <encounter> [<world> <x> <y> <z>]
Forces the system to check the current chunk, or the chunk containing the specified location to place an encounter. This performs terrain checks and places the encounter if a suitable location is found. The console command must specify the coordinates
re radius <encounter> <radius> [<world> <x> <z>]
Forces the system to check all chunks in a specified radius of chunks from the current player location or the location given by the specified chunk coordinates. The console command must specify the chunk coordinates
Installation
- To install the plugin, extract the contents of the zip file into your plugins directory.
- Default encounters are included in the RandomEncounters folder.
Bugs / Known Limitations
Because of the vast nature of this plugin, please use the GitHub Issue tracking system to submit bugs, issues, and feature requests.
GitHub Issue Tracking
Structure Contributors
Is this stable enough to be integrated into a 1.8 server? How much configuration will it take to get something like this up and running? Would it require a map reset of a server that already has player builds/faction bases?
For all intents and purposes, yes. Sad, but true. I no longer have the time to allocate to the development of this plugin. The source is available on github in should anyone wish to continue where I left off.
@ArchmageInc
Is this dead? I was one of the most awesome plugins! Is there any 1.8 dev builds I can get?
will the villages spawn if I just don't do anything at all with the config?
Getting console spam http://gyazo.com/c3819a8d025e398edf21ee99814e54db
Also lags my server hard
@TheTechPony
You tried using what? The savedEncounters.json? It is jumbled because it is in JSON format. You can paste the contents in something like http://jsonviewer.stack.hu/ and it makes it more readable.
The commands don't "generate" villages. They place, or attempt to place, encounters, which may be a village. Again, with large structures, like an entire villages, it will be difficult to place because of the landscape. In order to have an encounter grow into a village, all of the expansions must be configured to do so.
At this time, it does not align the structures in an organized way. A location is selected based on if the structure will fit, not if it makes sense, or is aligned to a road. That is the next major feature I hope to add.
Right now, I am flushing out the resource system for v0.4
@ArchmageInc
I tried using that but it seemed a bit jumbled. So, what would be the command to generate a village of this type?
@TheTechPony
Since the purpose of this plugin is to randomly place encounters, it is somewhat difficult to locate them. All placed encounters are stored in JSON format in the savedEncounters.json file by default. You can open that file and load it into a JSON reader to find the location.
As for having it generate an entire village, that can be done by loading the entire village as a single schematic (structure). The problem becomes locating a suitable place to put it. Larger structures are more difficult to place as it attempts to avoid griefing the landscape. This is why it is more beneficial for the encounter to be placed piece by piece through expansions.
How can I find a village that is created by this plugin? I'd also like to have it generate and entire village and not just bit by bit.
@PresidentBacon
Right now, this is not world aware with something like multi-verse. control over the nether and end were handled through biomes. In the 0.4.x release, I intend on adding validWorlds and invalidWorlds directives that operate similar to the biomes directives. It will be a big release though and will break some backward compatibility. I hope to have v0.4.3 available soon.
As for normal vanilla structures: no, this does not modify any current operations.
Does this apply to all worlds, or can you set it to just a certain world within the plugin or will Per World Plugins be able to prevent this plugin placing structures?
Also, does this completely replace villages, witch huts etc or do they spawn alongside any structures I set?
@AucunAuServ
I now it's separate. I have it on my server
@AucunAuServ
Good point. It wanted the third notation (5.6.0). I will try and get a correction out as soon as possible. Please post bugs in the ticket system.
When loading WordEdit 5.6, and the newest version of Random Encounters, v0.3.2, I get the following error:
Random Encounters requires at least version 5.5.8 of WorldEdit
As far as I can tell, 5.6 > 5.5.8
@ArchmageInc
This is an epic plugin, glad you made it and hope you will continue to do so.
All,
The latest file, v0.3.2 has the Y offsets corrected so they should not "grief" landscape. I would like to re-iterate that this plugin is a Beta. It is a really cool idea, and also very complicated. I am only one person and there are no other developers on this project. Threatening me with reporting this plugin for griefing is not going to motivate anyone to do anything. It is a BETA! I will do my best to respond to trouble tickets and get corrections out there. Keep in mind, I have a real job, it is more important that Minecraft plugins, it pays the bills, this does not.
Currently I have a report of a problem with this plugin and Multiverse. I have run tests with their latest stable build, but have been unable to reproduce these reports.
The source code for this plugin is public, and anyone is free to fork it to build on to it, or make it do whatever they want. I have tried to get this to a clean, stable, releasable state. I don't have an infinite amount of time, nor am I the world's best Java developer. I appreciate the help everyone has provided in beta testing this plugin and it feels like we are really close, yet at the same time, there is a lot of work left to do.
@BloodReaperArmy
Yes, this does require WorldEdit. I realize their latest stable is not at current version, though it is tested and works with current version
@MaxBFalcon
What I really hope to do is build a configuration utility that allows a graphical interface to modify the JSON configuration files. I have no time at the moment.
@jacob_vejvoda
Please log errors in the ticket system, I think we've had this conversation before.
As for the problem, this is not able to get the world name out of the location. When you add this error to the ticket system, please include any additional plugins you are using.
My terminal is getting spammed with this error:
Also can you add per world support?
Hey, I was wondering, are there any tutorials for this? It would help a lot if I was sure on what I was doing.. ;P
does this need world edit? this is 1.7 and that is 1.6 so how does that work?