NotOnMyLawn

This project is abandoned and its default file will likely not work with the most recent version of Minecraft. Whether this project is out of date or its author has marked it as abandoned, this project is no longer maintained.

What is NotOnMyLawn?

WARNING

The default settings used in the v1.2-beta build were broken. If you used the beta, you will need to delete the config file and let NOML create a new one. If you use a custom config and don't want to delete it, you can replace "LEAF" with "LEAVES" and "COBWEB" with "WEB", as those are the proper names for the blocks as exposed by Bukkit.

END OF WARNING

NotOnMyLawn is a mod that controls the spawning of mobs around man-made structures. It is strongly inspired by sluvine's CivilizedSpawn, but using completely new code.

Background Story

CivilizedSpawn was exactly what I was looking for, but it's not compatible with newer versions of Bukkit. Since I couldn't find any source code to work from, I reimplemented all the features of CivilizedSpawn based (roughly) on the description in the forum thread, and I'm comfortable that it should be at least as stable and fast as the original. Since sluvine probably spent some time tweaking the default values, I did use his values on this plugin.

Description and Features

NotOnMyLawn disallows mob spawns in areas where it detects man-made structures, by detecting the types of blocks in the vicinity of the spawn position and, if enough of them are crafted blocks, cancelling the spawn.

An optional feature (defaults to enabled) makes the plugin detect structures around the spawning position by searching around the vicinity of detected blocks and only marking that block as detected if there's enough blocks around it that are also detected. This prevents the plugin from cancelling spawns around misplaced blocks, markers or other tiny structures.

Because the normal operation would also disable spawns on generated structures like dungeons and abandoned mineshafts, and to allow the players to choose where they DO want monsters to spawn, there's also an option to allow spawns to happen near Mob Spawner blocks and Cobwebs.

Finally, to prevent monsters from spawning on treetops, when those trees are placed around your structures, there's an option to disallow spawning on a block that's surrounded by a number of leaves.

Installation and Configuration

NotOnMyLawn does not require any special installation steps, just place the provided NotOnMyLawn.jar file in your bukkit's plugins/ directory and it will create a default configuration file on the first run.

If you want to tweak the settings, open plugins/NotOnMyLawn/config.yml in your favorite text editor, change the settings, and reload the server (or disable and reenable NotOnMyLawn if you have a server plugin that provides such functionality).

The default setting values can be seen at the GitHub repository, along with comments describing them.

For a list of available block materials, see the Bukkit API documentation on Materials. Note that only block materials make sense for the scanners, not entities.

To understand how the scanner system works, you can read the Scanner Configuration page.

Commands and Permissions

Starting at version 1.1, NotOnMyLawn has a chat command for changing settings, /notonmylawn, that can be shortened to /noml. This command requires a permission notonmylawn.config, which defaults to allowing only ops.

Some of the following commands require a <config name> parameter, this is the name of the "path" within the config structure to reach the key, separated by ".", such as "treetops.allow".

/noml reload

This command reloads the config file and reinitializes the plugin with the new configuration.

/noml enable

This command is an alias for "set enable true"

/noml disable

This command is an alias for "set enable false"

/noml show <config name>

This command displays the current value for the given key.

/noml set <config name> <value>

This command attempts to change the value for the given key.

Example: To change the range of the "main" scanner to 20, do: /noml set main.range 20

/noml describe <scanner>

This command shows an overview of a scanner's settings.

Source Code

This mod is released under a 3-clause BSD License.

The source code is available in a public GitHub repository.

Future

All the features I had planned initially are implemented. From now on it will be a matter of maintaining the plugin: updating it to future versions of Bukkit, fixing any reported bugs, etc.

I'll also consider adding new features, if there's any request by the users.

About This Project

  • Project ID
    42515
  • Created
    Jul 28, 2012
  • Last Released File
    Aug 13, 2012
  • Total Downloads
    2,894
  • License

Categories

Members

Recent Files

Bukkit