spawns
Spawns is a plugin for Bukkit and Minecraft that allows you to fully customize the spawning behaviour of mobs on your server.
Features
- tweak the default Minecraft spawns or replace them completely
- set mobs to spawn under conditions they never normally would
- block certain mobs from ever spawning
- cause mobs to spawn with potion effects, equipment, saddles, etc.
- cause mobs to spawn in different variants, like powered creeper, wither skeleton, etc.
- mobs appear in the world in the same way as they do normally, so are compatible with all other plugins
Dive right in here to see how to make config files or keep reading for an overview of Minecraft spawning.
Default spawning
Minecraft spawning works like this:
Every spawn cycle (1 tick or 1/20 second by default for hostile mobs) the game makes a list of all the chunks around each player, up to a radius of seven chunks. Each chunk will only be counted once, even if that chunk is around several players.
Once this list is complete a mob limit is calculated. The limit is higher the more chunks are in the list. If the limit is lower than the current amount of a mob type in the world then the cycle will be cancelled.
If the limit is not yet reached a random block from each chunk in the list will be calculated and this chunk will be used as the centre point for a pack of mobs to spawn around. In order to continue, this block must be water for water mobs (only squid so far) and air for any other type of mob.
If this block is suitable then a maximum of 12 random blocks are chosen from up to 20 blocks away, but always at the same height as the centre block.
Lastly, The individual blocks are checked that they can physically fit the mob, so they need to be air, have air above and an opaque block below. The type of mob is chosen based upon the matching conditions (biome, height, floor block type, etc.) and the final mob is chosen randomly from all mobs that are eligible to spawn there. All other mobs in the pack will be the same type.
Permissions
spawns.can-reload-config, which allows the user to reload the config. Default is Op.
spawns.can-count-mobs, which allows the user to display a summary of mob amounts in a world. Default is Op.
Commands
/reload-spawns, or /rs, which reloads the config without having to reload the server. Any mobs already in the world will be unaffected by any changes in the config.
/count-mobs, or /cm, which displays a list of mob numbers in the world. Add a world name argument to specify a world (optional if run as a player) and / or a mob type argument to choose one type of mob to count.
Update checking
If you like, you can set the plugin to check for any newer versions that get released. To do this add an element to the config.xml file, like this:
<check-for-newer-version/>
When this element is present the plugin will report if it finds a newer version. This only works for release builds so you won't be bothered by any beta or dev builds. To disable this checking simply remove the element.
Note that no update will be downloaded even with this set.
Examples
I would love to get any example config/packs/mobs files you have created to add to the docs, so if you have one you're proud of send it in and I'll add it.
spawns took a lot of work, so if your server is enriched by it please consider sending some love my way!
<a href="https://www.paypal.com/cgi-bin/webscr?return=http://dev.bukkit.org/server-mods/mobs/&cn=Add special instructions to the addon author(s)&business=apodlesna@gmail.com&bn=PP-DonationsBF:btndonateCCLG.gif%3ANonHosted&cancelreturn=http%3A%2F%2Fdev.bukkit.org%2Fserver-mods%2Fmobs%2F&lc=US&itemname=spawns+%28from+Bukkit.org%29&cmd=donations&rm=1&noshipping=1¤cycode=USD"><img class="aligncenter" alt="donate" src="https://www.paypalobjects.com/enUS/i/btn/btndonateLG.gif" /></a>
If you're penniless or like spawns but not that much I'm also partial to TF2 items. Send any you don't want my way! STEAM id: coldntired
If you don't know what TF2 is, then start playing! It's free and fun!
For other projects, links, help, etc. please visit the main website.
You can also follow sylian.eu on Twitter for updates.
-
View User Profile
-
Send Message
Posted May 1, 2014Sorry if this question has been asked before, but how does one block the spawning of variations?
Primarily:
Thanks!
-
View User Profile
-
Send Message
Posted Apr 30, 2014@mushuweasel I would turn off any mob-related aspects of ClearLagg. It will mess up mob tracking.
Mobs despawn when players move away and chunks unload anyway.
-
View User Profile
-
Send Message
Posted Apr 29, 2014Heyoh, we're finding a rather major lag issue that's worsening as we further customize our Spawns installation. We use ClearLagg to manage entity cleanup, and every time the auto lag clear hits there, we have about 3-5s of dreadful cpu spike lag. My working theory at the moment is that ClearLagg wipe and Spawns .. spawning.. are in a race with each other in that wipe. I'll be doing some visualvm digging later to try to pinpoint more specifically where the spike is coming from.
Have you seen any issues around interactions with lag clear plugins? Any recommendations?
Many thanks
-
View User Profile
-
Send Message
Posted Apr 29, 2014@TheBowman42 No worries. That was one of the big changes in the config but I felt it was cleaner than something like this
Updated the wiki site including the conditions stuff http://wiki.sylian.eu/spawns/conditions
-
View User Profile
-
Send Message
Posted Apr 28, 2014@coldandtired
I appreciate your help and your patience. You are my hero. I am a dummy. I left out the hubs wrapper.
-
View User Profile
-
Send Message
Posted Apr 27, 2014@TheBowman42 The hub works in more or less the same way as the pack does. I added it to provide extra possibilities (different packs for different players, for example) but it's pretty optional. To use a default hub (which would be the same as the old config you can do this)
which will use the same block as the player to spawn the packs around.
The exact config I was using for testing looked like this (with things like equipment added when necessary)
If you still have problems shoot me a PM with what you've tried and I'll take a look.
-
View User Profile
-
Send Message
Posted Apr 26, 2014Howdy!
This is a fantastic thing you have here. I tested an older version of it and it made things do what I told them to. I haven't had this much control over something since I tried Mobs.
I'm having an issue with the current version. For the life of me, I can't make a hub. Is there any way I could sweet talk you into making an example of each config (especially the one hubs go in) that you know to work? The docs are extremely detailed and informative. It is because of this that I have difficulty following along because there is a lot to take in and it wasn't clear what it should look like when it is done.
-
View User Profile
-
Send Message
Posted Apr 25, 2014@WAP2011
<3
@Schlutteh
There is no option to select 1.7.9 when you upload a file yet so I had to select a different one. It is for 1.7.9 though.
-
View User Profile
-
Send Message
Posted Apr 25, 2014It says 1.7.9 b1 for 1.7.4.... typo?
-
View User Profile
-
Send Message
Posted Apr 25, 2014This.. this is amazing o_O
-
View User Profile
-
Send Message
Posted Apr 22, 2014Well, it's been a long time coming but I think I can't stare at the code any longer without going blind!
1.7.9 b1 is up (and being checked)
New docs, links, etc. for this version can be found here http://wiki.sylian.eu/spawns
Please read the docs, test the plugin, and let me know what doesn't work as expected and needs to be improved.
-
View User Profile
-
Send Message
Posted Apr 22, 2014@Schlutteh
@coldandtired
I just looked at the link below, if thats the same beta link you sent me. Been running it for over a week. I would not call it a beta. I came back to post that it was working great and we have a new issue with a current spigot build. http://pastebin.com/zZ9ifBxy thats the dev build on current spigot. not to worry Schlutteh. You should be fine to use it. I mean worst cause you mobs dont spawn. I dont see it being a server breaking issue if it does bug. Im still on a 1.7.5 build I believe and beta works great!
-
View User Profile
-
Send Message
Posted Apr 3, 2014@coldandtired
I'm still too scared to try the new beta!
But I only have my live server to test it on anyhow, so I gotta stick with the stable versions.
Looking forward to the new features though!
-
View User Profile
-
Send Message
Posted Apr 1, 2014@jhicks32917 The beta version is not completely working yet and uses a slightly different format to the stable and dev versions.
For now, I've reverted the old tutorial to deal only with the current format, and created a new site to deal with the beta. Note that as I'm still refining the code it's possible the beta docs and the beta jar don't match up from time to time.
The beta site is at http://wiki.sylian.eu/spawns
-
View User Profile
-
Send Message
Posted Mar 31, 2014Hello,
When I use the Beta or b5 the files config.xml and world.xml are produced with different code than what is on the help site and packs.xml and mobs.xml aren't produced at all.
Edit: Using Spigot 1330, 1.7.2.
-
View User Profile
-
Send Message
Posted Mar 31, 2014@coldandtired
good to know.
-
View User Profile
-
Send Message
Posted Mar 28, 2014@Spearhartt The tutorial (except for the old page) only applies to the beta version of the new Spawns. The current stable release (b5) and the dev version (b5 dev) still use the old config.
-
View User Profile
-
Send Message
Posted Mar 28, 2014@coldandtired
I'm using the ones you have available from your site. No modifications. This is what is in them:
<mobs>
<myBat>
<mob-type>bat</mob-type>
<weapon>
<material>iron_sword</material>
<drop-chance>78</drop-chance>
<lore>
<name>Big sword</name>
<line1>Magic sword</line1>
</lore>
</weapon>
</myBat>
</mobs>
-
View User Profile
-
Send Message
Posted Mar 28, 2014@Spearhartt It looks like a mob has a missing id. Can you paste your mobs.xml?
-
View User Profile
-
Send Message
Posted Mar 28, 2014@coldandtired
When loading the 1.7.5 dev build we're getting this error: http://pastie.org/8976129