minecraft:breedable for you with a switch.Get GodCraftOverview
minecraft:breedable is an entity component: it goes in the components object of a custom mob, or in one of its component groups. Lets two entities fall in love and make a baby when fed the right items. Pair it with minecraft:offspring (unless you use pregnancy), and the baby gets the minecraft:entity_born event.
Fields
| Field | Type | Default | Description |
|---|---|---|---|
allow_sitting | Boolean | "false" | Lets the entity breed even while it is sitting. |
breed_cooldown | Decimal | "60" | Seconds the entity must wait before it can breed again. |
breed_items | List | none | Items a player can feed to put the entity in love mode, with an optional item they turn into afterwards. |
breeds_with | List | none | Which entity types it can pair with, the baby type, and the event fired when they breed. |
causes_pregnancy | Boolean | "false" | If true, the entity becomes pregnant instead of a baby appearing right away. |
environment_requirements | List | none | Blocks that must be nearby before the entity can enter love mode. |
extra_baby_chance | Decimal | "0" | Chance from 0 to 1 that extra babies are born at once. |
love_filters | Minecraft Filter | none | Conditions that must pass for the entity to fall in love. |
require_full_health | Boolean | "false" | If true, the entity must be at full health to breed. |
require_tame | Boolean | "true" | If true, both entities must be tamed before they can breed. |
Example
Inside the components object of BP/entities/<name>.json (values are the defaults or placeholders):
BP/entities/<name>.json
{
"minecraft:breedable": {
"allow_sitting": "false",
"breed_cooldown": "60",
"breed_items": {},
"breeds_with": {},
"causes_pregnancy": "false",
"environment_requirements": {},
"extra_baby_chance": "0",
"love_filters": {}
}
}