Add cart property to disable spawning in TC loaded chunks #176


  • New
  • Enhancment
Open
Assigned to lenis0012
  • leagris created this issue Aug 19, 2013

    keepChunksLoaded is always a requirement for empty trains to travel some significant distance.

    Though, while chunk are loaded, creatures spawns in these and it cause a significant CPU load on servers.

    My server start to lag when total entity count reach 2500 or more.

    Monsters and animals spawn in chunks loaded by TrainCarts, is significant enough to cause an issue with long distances and large count of chunks loaded.

    Keeping rails area and tunels lit at minimum bl: 8, does not help on the too many entities loaded because it does not cover all chunks surface and caves and it does not prevent animals from spawning.

    WorldGuard regions and flags could be used to prevent mob spawning in all chunk near rails, but well, it would be simpler to have a train property to disable spawning in keepChunksLoaded chunks. Railways paths can be so twisted that defining proper regions, even polygonal is too complex and a maintenance issue.

    Having TrainCart disable natural spawning of monsters, animals as well as spawners, killing or freezing these entities in keepChunksLoaded chunks could significantly help here.

    Proposed cart properties:

    propertyvaluesdescription
    entity
    :All|Any
    :monsters
    :animals
    :PIG|BAT|SKELETON|…
    CANCEL|KILL|FREEZE
    :All
    :Natural
    :Spawner
    :Egg
    :Plugin
    Cancel spawning, kill or freeze activity of (default to all except minecarts, players, items), monsters, animals or specifically named entities or creatures (default to All) where a chunk is kept loaded by a TrainCart and no other plugin/player

    Implementation:

    Linking to WorldGuard, you could make use of a moving or auto-defined regions around cart groups or rails, and let WG handle the entity spawning and other flags.

    Linking to WorldGuard could help on implementing the waiter regions we talked about a few days ago :)

  • leagris added the tags New Enhancment Aug 19, 2013

To post a comment, please login or register a new account.