Custom Spawns [Fabric]

Mods
56,215 Downloads Last Updated: Jul 16, 2022 Game Version: 1.16.5   +1

Custom Spawns -- Configurable Mob Caps and Persistence

 

Fabric API and Cloth Config are required!

 

This is a simple server-side Fabric mod that allows you to configure various mob caps and persistence, as well as increase the rate of passive mob spawning. You can also use this to add or remove mob spawns from specific biomes.

 

Made as a companion mod to my old world gen mod, Modern Beta, you can use this to restore classic passive mob spawning!

 

=================================================================

 


Configuration

 

You can configure Custom Spawns through Mod Menu (recommended) or in the config/customspawn.json file.

The current options are:

Note: For the following options, please note the following formula used to calculate mob caps:

Actual Mob Cap = Mob Cap * Chunks [289 in Singleplayer] / (Spawn Chunk Constant ^ 2)

 

General

  • chunkConstant (default: 17): Constant to modify actual mob cap.
  • rareSpawnTicksToWait (default: 400): Number of ticks between rare mob spawn attempts. (20 ticks = 1 second)

 

Mob Spawn Group Options

  • capacity: Maximum mob cap.
  • peaceful: Whether mobs in this category are spawned as animals or monsters.
  • rare: Whether mobs in this category are spawned with the customizable rare spawn tick timer.
  • immediateDespawnRange: The distance at which mobs in this category immediately despawn, if not persistent.
  • despawnStartRange: The distance at which mobs start to have a change to despawn, typically 40 seconds, if not persistent.

 

Mob Persistence

  • passivePersistent (default: true): Enable/disable passive mob despawning.
  • hostilePersistent (default: false): Enable/disable hostile mob despawning.
  • ambientPersistent (default: false): Enable/disable ambient mob despawning.
  • waterPersistent (default: false): Enable/disable water mob despawning.
    Note: Non-persistent mobs can still be made persistent by renaming them or modifying the NBT tag. Saddled or tamed mobs should not despawn regardless of persistence setting.

 

Mob Spawn Additions

  • biomeId: Fully-qualifed biome Identifier.
  • mobId: Fully-qualified mob Identifier.
  • spawnGroup: Spawn group for the mob to be placed in. Can be one of: MONSTER, CREATURE, AMBIENT, WATER_CREATURE, WATER_AMBIENT, UNDERGROUND_WATER_CREATURE (1.17+), AXOLOTLS (1.18+)
  • weight: Spawn likelihood.
  • minCount: Minimum group size.
  • maxCount: Maximum group size.
    Note: Mobs may have their own spawn restrictions outside of the spawn group they are placed in (e.g. Phantoms do not check for the light level before spawning, so if added as a natural spawn to an overworld biome, they will spawn in broad daylight even if placed under the MONSTER category).


Config example:

{
     "biomeId": "minecraft:plains",
     "mobId": "minecraft:pig",
     "spawnGroup": "CREATURE",
     "weight": 10,
     "minCount": 4,
     "maxCount": 4
}

 

Mob Spawn Removals

  • biomeId: Fully-qualifed biome Identifier.
  • mobId: Fully-qualified mob Identifier.

Config example:

{
     "biomeId": "minecraft:plains",
     "mobId": "minecraft:pig"
}

 

Mob Spawners

  • overrideSpawnerDefaultValues: Toggle mob spawner settings. If you have custom spawners or another mod that modifies spawners, leave this off/false.
  • minSpawnDelay: Minimum tick delay between spawn attempts.
  • minSpawnDelay: Maximum tick delay between spawn attempts.
  • spawnCount: Maximum number of mobs that may be spawned.
  • maxNearbyEntities: Maximum number of nearby mobs of the same type before the spawn attempt fails.
  • requiredPlayerRange: Spawner activation spherical radius.
  • spawnRange: Mob spawn radius.

 

Following the Beta 1.2_01 spawning algorithm, to restore classic Beta mob spawning, use the following values:

  • Spawn Chunk Constant: 15
  • Creature Mob Cap: 15
  • Passive Mob Rare Spawn: False
  • Passive Mob Persistence: False
  • All other options should be left at default.

 

Comments

Posts Quoted: