The mob module allows for the spawning in of mobs using the /spawnmob
command.
The command /spawnmob [player] <mob> <amount>
allows the user to spawn mobs around the specified player (or themselves,
if not specified), the mob, and the number of mobs. Vanilla mobs do not require a prefix (but you may use the prefix minecraft:
),
other mob types must be prefixed by the mod’s ID.
So, to spawn in 20 chickens around you, use the command /spawnmob chicken 20
or /spawnmob minecraft:chicken 20
.
Administrators can limit the number of mobs that are spawned in at once by setting the desired maximum for the config
option mob.max-mobs-to-spawn
in the main.conf
file. This defaults to 20.
Nucleus can limit the types of mobs that are spawned in by players. To enable this, set mob.separate-mob-spawning-permissions
to true
in main.conf
.
Nucleus will make an additional permission check to check whether a player can spawn a mob. The permission is
nucleus.spawnmob.mobs.<mobid>
, where the mobid has any “:” (colons) replaced with “.” (period).
So, the permission to allow a player to spawn a creeper in would be nucleus.spawnmob.mobs.minecraft.creeper
.
This allows server owners to allow all vanilla mobs with the permission nucleus.spawnmob.mobs.minecraft
.
Nucleus can control the mobs that cannot be spawned into a world, either by command, spawner or naturally. In main.conf
,
mob.spawning-blocks
will look like this by default:
# Controls the mobs that cannot be spawned. Each section is world specific, with the key being the world name in question, which is case sensitive.
spawning-blocks {
DIM-1 {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=[]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=false
}
DIM1 {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=[]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=false
}
world {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=[]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=false
}
}
Each section is world specific, with the key being the world name in question, which is case sensitive. Mob IDs must be the
full ID, so any vanilla Minecraft mob would be prefixed with minecraft:
. If you wanted to block creepers and spiders from the overworld (world
)
ghasts from the nether (DIM-1
), and all vanilla mobs from the end (DIM1
), you would change the block to look something like this:
# Controls the mobs that cannot be spawned. Each section is world specific, with the key being the world name in question, which is case sensitive.
spawning-blocks {
DIM-1 {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=["minecraft:ghast"]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=false
}
DIM1 {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=[]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=true
}
world {
# The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:"
block-mobs-with-ids=["minecraft:creeper", "minecraft:spider"]
# If true, all vanilla mobs will be blocked in this world.
block-vanilla-mobs=false
}
}
Note that in order for the HOCON to be valid, quote marks must be put around the mob IDs.
Nucleus will gain the ability to create mob spawners, once Sponge implements what is required.
The following are incompatibilities that may occur with this module, along with how to resolve the problem. For the full mod/plugin incompatibility list, see the compatibility page.
No plugin incompatibilities have been reported.
Aliases:
/spawnmob
, /spawnentity
, /mobspawn
Usage: /spawnmob [<player>] <mob> [<amount>]
Default Role: ADMIN
Basic Command Permission: nucleus.spawnmob.base
Permissions
nucleus.spawnmob.exempt.cost
- Default Role: ADMIN nucleus.spawnmob.exempt.warmup
- Default Role: ADMIN nucleus.spawnmob.exempt.cooldown
- Default Role: ADMIN nucleus.spawnmob.base
- Default Role: ADMIN nucleus.spawnmob.others
- Default Role: ADMIN
This command is an equivalent to the following command(s) in Essentials:
/spawnmob
, /mob
Permission | Suggested Role | Description |
---|---|---|
nucleus.spawnmob.base | ADMIN | Allows the user to run the command /spawnmob |
nucleus.spawnmob.exempt.cooldown | ADMIN | Allows the user to bypass the cooldown for /spawnmob |
nucleus.spawnmob.exempt.cost | ADMIN | Allows the user to bypass the cost for /spawnmob |
nucleus.spawnmob.exempt.warmup | ADMIN | Allows the user to bypass the warmup for /spawnmob |
nucleus.spawnmob.others | ADMIN | Allows the user to target other players using the command "spawnmob". |
# The maximum number of mobs that can be spawned using /spawnmob. max-mobs-to-spawn=20 # If true, Nucleus will make an additional permission check to check whether a player can spawn a mob. # The permission is "nucleus.spawnmob.mobs.<mobid>", where the mobid has any ":" (colons) replaced with "." (period). So, the permission to spawn a creeper would be # "nucleus.spawnmob.mobs.minecraft.creeper". This allows server owners to allow all vanilla mobs with the permission "nucleus.spawnmob.mobs.minecraft". separate-mob-spawning-permissions=false # Controls the mobs that cannot be spawned. Each section is world specific, with the key being the world name in question, which is case sensitive. spawning-blocks { DIM-1 { # The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:" block-mobs-with-ids=[] # If true, all vanilla mobs will be blocked in this world. block-vanilla-mobs=false } DIM1 { # The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:" block-mobs-with-ids=[] # If true, all vanilla mobs will be blocked in this world. block-vanilla-mobs=false } world { # The full IDs of the mobs to block. Minecraft mobs have an id starting with "minecraft:" block-mobs-with-ids=[] # If true, all vanilla mobs will be blocked in this world. block-vanilla-mobs=false } }