Randomly generates temporary resource nodes and other structures in an existing world
ResourceSpawner spawns things at random locations, and optionally decays them after an amount of time

An example resource field, with resource nodes spawning and decaying at an unreasonably high rate
(There is no limit to the size of the spawned structures)
The long versionEach cycle, each Resource Spawner will:
World providers provide a list of worlds a Resource Spawner may operate in.
Location providers provide an area a Resource Spawner may operate in, such as a cuboid, sphere, etc.
Some location providers offer Distributions, to allow generation bias towards certain areas
Spawn providers spawn something in the location, such as a structure or entity
Structure Providers are a special type of Spawn Provider that will spawn a structure. Since structure generation speed is limited, you can choose a Structure Sorter to define in what order the blocks will spawn or decay
Structure Providers allow you to schedule the structure to decay after a given amount of time. This time can be reset by Triggers
Triggers will reset the timer on a structure provider when a specific event happens, such as a block being broken or a player moving nearby. Triggers can be set to reset the time to any value.
Conditions check the area around a spawn for specific features before allowing it to continue.
All significant actions in ResourceSpawner, from scanning a large area to spawning a single entity, are limited to spend no more than a given amount of time per tick. This is configurable, in nanoseconds, for each resource spawner
In addition, resource spawners can be set to only tick at specific intervals
Plugins can register new World Providers, Location Providers, Spawn Providers, Conditions, Structure Sorters, Triggers, and Distributions by listening for the ResourceSpawnerInitializationEvent and using its register methods.
For examples of these, see the Source Code
Note: Your plugin should use itself for the NamespacedKey, not ResourceSpawner
ResourceSpawner uses Hjson for its configuration to avoid the messiness of YAML, while still providing a reasonably user-friendly configuration file
Basic configuration format{
debug: false //this line is optional, but set it to true to enable an excessive amount of console output for debugging (This may slow down the plugin)
resource_spawners: [
{
//a resource spawner
}
{
//another resource spawner
}
]
}
For the formats of Resource Spawners and everything else, see the Features List section
My plugins will always be free, but donations would be very much appreciated :)
Consider supporting me on patreon:
For full documentation, see GitHub