CloserMobSpawns icon

CloserMobSpawns -----

Prevent mobs from spawning in caves far away from everyone



Commands:
/cms reload ---- reloads the config.yml
/cms debug ---- logs debug information to help visualizing how your rules are affecting mob spawns
/cms about ----- displays information about the plugin
/cms help ------- shows help message

Permissions:
cms.reload, cms.debug, cms.help, cms.about

Config.yml:
Contains the rules that will determine under which conditions a mob spawn will have a chance to be cancelled. A rule has format:
if distance1 [sign] value1 and distance2 [sign] value2 and distance3 [sign] value3 ... then cancel-spawn-chance = value

You can add as many statements separated by "and" as you want.
The sign can be either > or <.

Distance types: distance, horizontal-distance, vertical-distance

Rule examples:

if distance > 72 then cancel-spawn-chance = 75

if horizontal-distance > 32 and distance > 48 then cancel-spawn-chance = 30

if horizontal-distance > 20 and distance > 32 and vertical-distance > 16 then cancel-spawn-chance = 30


Invalid rule examples:
❌ if distance = 10 then cancel-spawn-chance = 75

❌ if horizontal-distance > 36 or distance > 72 then cancel-spawn-chance = 50


You can't use 'or' as logic operator because you can just add another rule instead, because rules will be applied one after another, from top to bottom. But as soon as one of the rules decides to cancel a mob spawn by chance, all the next rules will be ignored. That means you can use add cancel-spawn-chance = 100 to skip all subsequent rules.
Resource Information
Author:
----------
Total Downloads: 234
First Release: Feb 1, 2022
Last Update: Feb 5, 2022
Category: ---------------
All-Time Rating:
1 ratings
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings