promotional bannermobile promotional banner
premium banner
Simple animal growth / taming plugin.

Description

DISCLAIMER: This does not work on latest update.

I'll eventually come back to updating this, but crunch time has hit for the startup I'm in, and coding for 16hrs/day is not always my first choice :)

Thanks for understanding.


Wait? the animals don't grow up yet? - me, having waited 4hrs

A very tiny (for now) plugin/mod which adds a few main behaviours to the Livestock category of animals. I read somewhere that the devs said we should feel free to extend the systems that we feel are missing, so here's an attempt at helping out.


Features:

Growth

  • Animals now grow up from their juvenile stage, to their adult stages over time.
  • Who does what is entirely overridable and configurable through the Asset editor. If you want your chickens to grow up into skeletons -- see the configuration section.
  • By default; animals take 5 in-game days to grow up, starting from their spawn instant. I set this reasonably high as the game is about adventure.

Custodianship

  • Animals can now be fed their favourite foods, and have a chance to view you as their custodian when you feed them enough.
  • Animals who view you as a custodian will be friendly and approach you even when you're wielding weapons. Not everything is forgiveable however, so they'll still run if you attempt to get their light/medium/heavy hide.
  • Becoming a custodian of an animal will allow you to take advantage of the breeding system, as you'll be able to feed them without cautiously approaching them first.
  • Animals which have been tamed will by default not despawn and won't count towards new spawning, but if this is a problem on your server, check the configuration section.

Breeding

  • Animals can now breed. At least the mammals. By default, they can mate every 2 days.
  • When fed by a custodian, animals who haven't mated recently will look for a new mate, and when found, a wonderful new little leather-to-be animal is spawned.
  • Animals born from breeding, are immediately assigned the same custodians as the parent which gave birth, making them domesticated and no longer despawnable.
  • Egg-based animals currently aren't enabled by default (since it'd be fun if they actually hatched from fertilized eggs); see the configuration section if you'd like to know how to enable that.
  • Bunnies and rabbits seem like separate species in this game, so those too aren't configured for breeding.

Favourite food overview

A quick reference of the default "LovedItems" which shipped with the game:

Favourite Food Animals
Plant_Fruit_Apple Ram, Ram_Lamb, Mouflon, Mouflon_Lamb, Goat, Goat_Kid
Plant_Crop_Carrot_Item Horse, Horse_Foal, Rabbit, Bunny
Plant_Crop_Corn_Item Chicken, Chicken_Chick, Chicken_Desert, Chicken_Desert_Chick, Turkey, Turkey_Chick
Plant_Crop_Cauliflower_Item Cow, Cow_Calf
Plant_Crop_Lettuce_Item Sheep, Sheep_Lamb
Plant_Crop_Wheat_Item Camel, Camel_Calf
Plant_Crop_Mushroom_Cap_Brown Pig, Pig_Piglet
Plant_Crop_Mushroom_Cap_Red Boar, Boar_Piglet
Plant_Crop_Pumpkin_Item Pig_Wild, Pig_Wild_Piglet
Plant_Crop_Chilli_Item Skrill, Skrill_Chick
Plant_Fruit_Berries_Red Warthog_Piglet
(none) Bison, Bison_Calf, Warthog


Animal configurations

These are exposed configuration values for each NPC; altering these at the NPC/Role/Asset level will need you to also inherit from the Template_AnimalHusbandry_Enabled template instead of the default Template_Animal_Neutral one.

For clarity, these are in game times.

Parameter Default Value Description
AdultRole "" The role to transform into after a provided growth range (for baby animals)
ChildRole "" The role which should be spawned when the NPC has successfully mated
ChildToAdultTimeRange* ["P5D", "P1Y"] Time range within which a baby role transforms into its AdultRole.
FeedTimeout ["PT1M", "PT1M"] Timeout between possible feed events (1 minute)
IsDomesticable true Indication that the animal can be domesticated
BreedingCooldownDuration ["P2D", "P2D"] Timeout before child can be birthed after mating (2 days)
BreedingTargetSlot "" Slot for storing current breeding target when finding a mate

* Set the end of the range to sometime far in the future, as entities who do aren't loaded _within the range will miss their growth sensor event_

Plugin configuration

The plugin overall configuration settings can be altered by creating a

mods/uzerai_animalhusbandry/AnimalHusbandry.json config file.

The default values for this configuration file is:

{
  "DisableDomesticatedCulling": true
}

Technical note

To get into the details; all of these behaviours can be configured by an NPC Role referencing Template_AnimalHusbandry_Enabled instead of Template_Animal_Neutral.

Do beware though, the Template_AnimalHusbandry_Enabled is a copy and extension of Template_Animal_Neutral so I'd avoid inheriting this for hostile or intelligent creatures.

The reason they aren't inheriting from another is that I needed some behaviours to be ignored when the target is a custodian (from the default Template_Animal_Neutral. (See source)

Known bugs

  • Horses cannot currently be mounted (reported by dinogutt).
    • Fixed release is being validated in curseforge, available on Github.
  • Animals can sometimes end up in a weird state where they won't regard the custodian as a friend, most likely related to the default ignore behaviour.
    • (it was default ignore behaviour, leaving that alone)