EntitySuppressor
EntitySuppressor is a plugin designed to prevent unnecessary amounts of Mobs from spawning on your server, thus reducing server lag. It does this by supplying an efficient multi-step process to limiting monsters.
Code is written almost entirely by myself. Also see bergerkiller's NoLagg for further Lag-Fixes. Credit to NoLagg & LexManos's PerformanceTweaks for some original concepts.
Features!
Quote:
- Multiworld compatibility!
- Limits Monsters, Squid, Animals, Bats, and Villagers to configureable amounts in rather efficient way.
- Can limit how far and/or how many layers away monsters spawn.
- Reduces the frequency of mob-spawn ticks.
- Only limits naturally spawned and spawner-spawned Mobs.
- When a world has reached it's maximum, spawner mobs are queued until there is room.
- Ability to remove far away unnecessary monsters.
- Does not remove mobs that have picked up player items.
- Commands to count the number of living entities.
- Commands to remove living entities.
- Reloadable config.
- Configurable debug mode that prints extra information.
- CraftBukkitUpToDate compatibility.
- Anonymous statistic reporting to mcstats.org!
Commands & Permissions
- /es count - Returns a count of all Living Entities in the current world.
- /es remove <all / monsters / animals> - Removes all of the specified entity group from the current world.
- esuppressor.remove - Required to use /es remove.
- If "all" is added to the end of either of the above commands, it will do it in all worlds.
- If <world> is added to the end of either of the above commands, it will only do it in the specified world.
- /es reload - Reloads the config.
- esuppressor.reload - Required to use /es reload.
@SERVERCONSOLE
That's because you can't legitimately write or read that from the new config system, that's why I said I would edit it.
Sorry my config is messed up somewhere. You need a space after the colon for each setting and I am now getting a Null Pointer Exception. My mistake. Trying to find it now. Sorry
I'll try making a slightly edited version of that the header.
checkDifference defaults to a divisor of (max / 8), and unless you're feeling twiddly you should never need to change it. In a future version it will be removed in favour of a parabolic function. at 64 you should never ever have or use .5 (32), that would be terribly inefficient.
I'm just going to not deal with animals other than squid right now. This is because way to many squid spawn, and no-one ever keeps them. I could cancel natural animal spawns (Think, v2.1), but I cannot remove excess animals. To be able to remove animals I would need people to be able to own the animals, which would require a whole bunch of extra stuff. I'd likely just make an animal protection plugin and then tie it into this.
v2.0 will have an option to not count them in the limiter though.
I was just looking at this and thinking it would be nice to be able to have a configurable ratio of animals to monsters. So, out of 128 mobs, if I have mobRatio set to 0.25, 32 will be animals and 96 will be monsters.
As I write this I'm wondering how this affects people who have farms. Like pens for keeping cows etc.
Use # to add comments.
Can't wait for 2.0! Esp the per player limits and proximity respawning.
Also suggest changing checkDifference to a multiplier rather than a fixed number. So I might use 0.5. If I my max is 64 - will allow more spawns at 32. I like that feature though.
Try this for a config. Let me know if I have misunderstood anything! Hope it helps!
################################################################
#
# EntitySuppressor Configuration
# Developer:Fishrock123
# Report bugs and feature requests to: [URL]
#
# REMEMBER: Animals are Mobs too!
#
################################################################
# Set default total maximum mobs - applies to each world
# This is the total mobs regardless of player count
DefaultMaximum: 128
# Limit squids as a part of the total maximum mobs
limitSquid: true
# Set total maximum mobs per world
# Use FALSE to REMOVE limits from a world
# Use TRUE to FULLY limit the world - NO MOBS
WorldMaximums:
world: 128
world_nether: 32
world_the_end: 64
# Set number of milliseconds between checks to allow additional mobs
SpawnFlagsCheckInterval: 200
# Set the point at which more mobs are allowed to spawn
# If max is set to 64 then 64-(64/8)=56
# When the total count is 56 additional mobs can spawn
# If this is disabled, the difference is 1/8 of the max
#checkDifference: 8
# Include mob spawners in the total
# Use FALSE if you do not want to have spawners limited
LimitSpawners: False
# Turning this off is not suggested
UseSpawnFlags: True
# Get extra debugging information
debug: False
####### DEPRECATED SETTINGS - REMOVE IF YOU HAVE THEM #######
#
# ESConfigVersion
#
# maxMonsters:
# Replaced by DefaultMaximum
#
# nonLimitedWorlds:
# Integrated into WorldMaximums
#
################################################################
@SERVERCONSOLE
Did you find what you were looking for? Does it make sense?
LOL - I just used up my STUPID for the month! After careful consideration, I believe "Configuration" is probably the best word to use in links to the configuration. ;o)
@SERVERCONSOLE
You couldn't find it? Theres a decent sized link that says "Configuration" in the description.
The information should be in there.... The config is somewhat obscure, I know. I'm not sure how to put comment code in the config, and if you have any suggestions as to better name the config options, please say so. :D
Btw: the next update will be 2.0 ;P
Downloaded plugin - looks like just what I need but I'm not sure what each config setting does exactly. Esp looking at WorldMaximums - you have the examples as true, false and 82 respectively. What do these do? What is the SpawnFlagsCheckInterval?
Sorry if this is covered somewhere but I couldn't find the documentation. Maybe some comment code in the config?
Looking forward to the updates you mentioned for 1.5. Thanks for all the great work!
Not sure if anyone pays attention to this, but v2.0 is well under way!
Right now there are some silly bugs I'm trying to banish, but after that it should be ready for deploying!
.... It's quite a tasty update. :3
@eldarstorm
Please submit a ticket containing the usual plus a Stacktrace, the CB Build, and anything else peculiar.
Getting: [SEVERE] Error occurred while enabling EntitySuppressor v1.4 (1I5) (Is it up to date?): null
Updated.
I support this plugin, Fishrock123.... you rock!
This is a simple, lightweight plugin that allows server owners to set a mob capacity.
Everything appears to be working! Thanks for the updates man!
@Fishrock123
I suppose the goal there would be to not limit the mobs in "The Awesome Mob Fighting World", and keep mob spawns to a minimum in the other worlds.
I hope that sheds a bit more light on the request.
@GameCharmer
That would seem kind of redundant, considering the plugin's purpose?
It may be possible, I'll look into it.
@Fishrock123
Would it be possible in the config to not have this plugin effect specified worlds? :)
Excellent work man!
@GameCharmer
It is multiworld compatible. It reduces monsters on all worlds, Player commands give the current world, and using es count from the server console returns all worlds. I'll update the description with that info.
I'll add /es count all. If something doesn't work, leave a ticket. :)
Is this multi-world compatable? It would be nice to run /es count WORLD to see what is going on in a world or /es count ALL (or something) to see activity on all worlds.