Realistic Plant Growth
  • ๐Ÿ‘‹Welcome to Realistic Plant Growth
  • Overview
    • โœจFeatures
    • โ‰๏ธFAQ
    • Commands
    • Permissions
  • Guides
    • ๐Ÿ–ฅ๏ธInstallation
    • ๐Ÿ› ๏ธConfiguration
      • โš™๏ธConfig.yml
      • ๐ŸŒ…BiomeGroups.yml
      • ๐Ÿ“ŠGrowthModifiers.yml
  • For Contributors
    • โ˜•Support me
    • ๐ŸŒFor Translators
    • ๐Ÿ–ฅ๏ธFor Developers
      • API
  • Links
    • GitHub
    • Modrinth
    • Spigot
    • Discord
    • Donate
Powered by GitBook
On this page
  • Introduction
  • GrowthModifiers File Structure
  • Key Sections
  • PLANT_NAME:
  • BiomeGroup
  • Groups
  • BiomeGroupName
  • Default
  • Example Configurations
  • Example 1
  • Example 2
  • Example 3
  • Advanced Topics
  • Order of valid Biome Checking
  • Growth Modifier Selection

Was this helpful?

Edit on GitHub
  1. Guides
  2. Configuration

GrowthModifiers.yml

Configuration Guide for Growth Modifiers.

PreviousBiomeGroups.ymlNextSupport me

Last updated 5 months ago

Was this helpful?


Introduction

The Realistic Plant Growth GrowthModifiers configuration file allows you to adjust the growth rate behavior of specified plants in relation to the vanilla game. By default, a growth rate of 100% mirrors vanilla behavior. Higher rates can speed up plant growth, while lower rates can slow it down.

This guide will walk you through the process of customizing these settings to fit your gameplay preferences. The best way to do this is, by providing example configurations and explaning them in detail.

Plants not listed in the GrowthModifiers.yml file will use the vanilla Minecraft plant growth behavior.

Growth rates above 100% (compared to vanilla Minecraft) are not supported during the BETA phase of this plugin.


GrowthModifiers File Structure

The following sections outline possible components of a plant configuration. Some of these sections are mandatory, while others are optional. Please note that there is a specific order in which the plugin checks these sections, and this order should be considered during configuration.

GrowthModifiers.yml
PLANT_NAME:
  BiomeGroup:
    Groups:
      - BiomeGroupName1
      - BiomeGroupName2
    BiomeGroupName1:
      GrowthRate: X
      UVLightGrowthRate: Y
      NaturalDeathChance: Z
      UVLightDeathChance: W
  Default:
    GrowthRate: X
    UVLightGrowthRate: Y
    NaturalDeathChance: Z
    UVLightDeathChance: W
    Biome:
      - BIOME1
      - BIOME2

Key Sections

The GrowthModifiers configuration file includes several parameters to adjust plant growth rates and death chances. Below are the key sections and parameters you need to understand.

PLANT_NAME:

PLANT_NAME:
  # The Material name of the plant you are configuring.
  # The configured GrowthModifiers are then applied to this plant.
  # This must be a Minecraft Material name (e.g., BAMBOO, CACTUS).

Some material names are mapped to simplify the configuration process. For example, instead of using MELON_STEM, you can use MELON to configure the growth of melons.

BiomeGroup

This section is specifically for handling biome groups. These groups can be created in the BiomeGroups.yml file.

Groups

A list of BiomeGroup names you configured in BiomeGroups.yml.

Groups:
  - BiomeGroupName1
  - BiomeGroupName2
Empty Groups List Example
PLANT_NAME:
  BiomeGroup:
    Groups: [ ]

BiomeGroupName

Each biome group can have specific settings for growth rates and death chances. Replace BiomeGroupName1 and BiomeGroupName2 with your actual biome group names.

BiomeGroupName1:
  GrowthRate: X  # The growth rate percentage for this biome group.
  UVLightGrowthRate: Y  # The growth rate percentage under UV light for this biome group.
  NaturalDeathChance: Z  # The chance of natural death for plants in this biome group.
  UVLightDeathChance: W  # The chance of death under UV light for plants in this biome group.

Default

The default configuration applies to all biomes listed under Biome and if no specific biome group configuration is set.

If your Biome list consists only of the keyword ALL, the Default section applies to all possible biomes.

Default:
  GrowthRate: X  # The default growth rate percentage.
  UVLightGrowthRate: Y  # The default growth rate percentage under UV light.
  NaturalDeathChance: Z  # The default natural death chance.
  UVLightDeathChance: W  # The default death chance under UV light.
  Biome:
    - BIOME1  # List of biomes included in the default group.
    - BIOME2

To use non-vanilla biomes, reference them by their correct namespace. For example, for a biome from the Terralith Datapack, use terralith:moonlight_valley

The Default section also serves as the fallback configuration for any BiomeGroups not covered by a dedicated section.


Example Configurations

Here are some example configurations with explanations to help guide you through the configuration process.

Example 1

In this example, the Bamboo plant's growth parameters are being configured. The configuration assigns the BiomeGroup called Tropical to the Bamboo plant , and further specifies its growth characteristics within this group.

The configuration also sets a NaturalDeathChance of 5%, indicating a small chance of Bamboo dying naturally in tropical biomes. In contrast, the UVLightDeathChance is set to 15%, reflecting a higher chance of Bamboo dying in underground farms lit by UV-Light Blocks compared to those exposed to natural skylight.

Example 1
BAMBOO:
  BiomeGroup:
    Groups:
      - Tropical
    Tropical:
      GrowthRate: 100
      UVLightGrowthRate: 35
      NaturalDeathChance: 5
      UVLightDeathChance: 15
  Default:
    Biome: [ ] # No growth in other biomes
BiomeGroup: Tropical
BiomeGroups.yml
# Tropical biomes
Tropical:
  # Jungle
  - JUNGLE
  - BAMBOO_JUNGLE
  - SPARSE_JUNGLE
  # Swamp
  - MANGROVE_SWAMP
  - SWAMP

Example 2

In this configuration example, the growth parameters for the Cocoa plant are defined. The BiomeGroup section, which typically defines specific biome groups with tailored growth settings, is assigned an empty list in this case. This indicates that no specific biome groups are configured for Cocoa, and the configuration relies entirely on the Default section for its settings.

The configuration also defines the chances of Cocoa plants dying under different conditions. The NaturalDeathChance is set at 5%, indicating a slight chance of Cocoa dying naturally in jungle biomes. The UVLightDeathChance is set at 25%, reflecting a higher chance of Cocoa dying when exposed to UV light in underground farms.

Lastly, the Biome key within the Default section lists specific biomes where Cocoa growth is allowed. These include JUNGLE, BAMBOO_JUNGLE, and SPARSE_JUNGLE, restricting Cocoa growth exclusively to these jungle biomes.

Example 2
COCOA:
  BiomeGroup:
    Groups: [ ]
  # The default section applies only to jungle biomes
  Default:
    GrowthRate: 100
    UVLightGrowthRate: 55
    NaturalDeathChance: 5
    UVLightDeathChance: 25
    # Cocoa growth is limited to jungle biomes
    Biome:
      - JUNGLE
      - BAMBOO_JUNGLE
      - SPARSE_JUNGLE

Example 3

In this configuration example, the growth parameters for melons are defined based on the biomes in which they are grown. The configuration specifies two biome groups, DesertBiomes and ForestBiomes, and also includes specific rules for the PLAINS and SWAMP biomes. Together, these define where melons can grow and what growth behavior to expect.

The DesertBiomes group has its own dedicated section, which adjusts melon growth to reflect the harsher conditions of desert environments. The GrowthRate is reduced to 50%, meaning melons grow more slowly in these biomes. However, if UV-Light Blocks are used, the UVLightGrowthRate increases to 75%, providing a slight improvement in growth speed under artificial light. The NaturalDeathChance is set at 10%, indicating a higher risk of melons dying naturally in deserts, but this risk is mitigated when UV light is present, reducing the UVLightDeathChance to 5%.

In contrast, the ForestBiomes group does not have its own modifier section. Instead, these biomes fall under the settings defined in the Default section. The same applies to PLAINS and SWAMP biomes, which are explicitly listed under the Default section. Here, melons grow at the standard GrowthRate of 100%, mirroring vanilla Minecraft behavior. The UVLightGrowthRate is also set to 100%, allowing for typical growth under UV light. The NaturalDeathChance is relatively low at 5%, with an even smaller UVLightDeathChance of 3%, making these biomes more favorable for melon cultivation.

The Default section also serves as the fallback configuration for any BiomeGroup not covered by a dedicated section. By including PLAINS and SWAMP directly and applying it to ForestBiomes, the Default section ensures that melons grow consistently in these environments without additional customization.

Example 3
MELON:
  Groups:
    - DesertBiomes
    - ForestBiomes
    
  DesertBiomes: # Applies to all biomes in the DesertBiomes group.
    GrowthRate: 50  # Slower growth in desert biomes.
    UVLightGrowthRate: 75  # Slightly faster growth under UV light in deserts.
    NaturalDeathChance: 10  # Higher natural death chance in deserts.
    UVLightDeathChance: 5  # Lower death chance under UV light in deserts.
  
  Default: # Default section applies to the PLAINS, SWAMP and all ForestBiomes biomes.
    GrowthRate: 100  # Default growth rate matches vanilla behavior.
    UVLightGrowthRate: 100  # Default UV light growth rate matches vanilla behavior.
    NaturalDeathChance: 5  # Default natural death chance.
    UVLightDeathChance: 3  # Default UV light death chance.
    Biome:
      - PLAINS
      - SWAMP
BiomeGroup: DesertBiomes
BiomeGroups.yml
DesertBiomes:
  - DESERT
  - BADLANDS
BiomeGroup: ForestBiomes
BiomeGroups.yml
DesertBiomes:
  - FOREST
  - FLOWER_FOREST
  - DARK_FOREST

Advanced Topics

Order of valid Biome Checking

When determining which BiomeGroup a specific biome belongs to during a growth event, the system checks the order of appearance in the BiomeGroups.yml configuration file.

If a biome is assigned to multiple BiomeGroups, only its first appearance in the file is considered valid. Subsequent appearances of the same biome in other BiomeGroups are ignored during this decision-making process.

This means the order in which biomes are listed within BiomeGroups.yml is critical.

For example, if the DESERT biome is listed first under the DesertBiomes group and later under AridBiomes, the system will recognize it only as part of DesertBiomes for that plant. The AridBiomes assignment would be ignored during growth calculations.

To avoid conflicts or unintended behavior, you should ensure that:

  1. Each biome is assigned to only one BiomeGroup.

  2. If assigning a biome to multiple groups is unavoidable, carefully order the groups in BiomeGroups.yml based on priority, keeping the first appearance rule in mind.

Growth Modifier Selection

This table illustrates the conditions under which different growth events for plants occur.

Each condition is determined by four factors: whether the biome is valid, whether the environment is dark, whether UV light is enabled, and whether fertilizer is active. Depending on the combination of these factors, one of four outcomes (or a special case) is triggered.

Key Factors:

  1. Valid Biome: Indicates if the plant is in a biome where growth is allowed. A valid biome is essential for normal growth.

  2. Is Dark: Specifies whether the environment is dark. Darkness can inhibit growth or trigger plant death in some cases.

  3. UV Enabled: Determines if UV light is present. UV light can promote growth or act as a special modifier.

  4. Fertilizer Enabled: Indicates whether fertilizer is active. Fertilizer often enhances growth under valid conditions.

Valid Biome
Is Dark
UV Enabled
Fertilizer Enabled
Event

false

false

false

false

Kill Plant

false

false

false

true

Fertilizer

false

false

true

false

Kill Plant

false

false

true

true

Fertilizer

false

true

false

false

Kill Plant

false

true

false

true

Kill Plant

false

true

true

false

Kill Plant

false

true

true

true

Special Case - UV-Light * Fertilizer

true

false

false

false

Normal

true

false

false

true

Normal + Fertilizer

true

false

true

false

Normal

true

false

true

true

Normal + Fertilizer

true

true

false

false

Kill Plant

true

true

false

true

Kill Plant

true

true

true

false

UV-Light

true

true

true

true

UV-Light + Fertilizer

Growth Event Outcomes:

  1. Kill Plant: The plant gets killed, regardless of other factors.

    • Example: If a plant is in an invalid biome without fertilizer, it will die immediately.

  2. Fertilizer Effect: Fertilizer can enable growth even in an invalid biome at a reduced growth rate.

    • Example: In an invalid biome with fertilizer applied, the plant can grow at the fertilizer_invalid_biome_growth_rate

  3. Normal Growth: When the plant is in a valid biome, it grows under default conditions defined by GrowthRate and NaturalDeathChance.

    • Example: A plant in a valid biome, without UV light or fertilizer, grows at the standard rate.

  4. Normal Growth with Fertilizer: If fertilizer is applied in a valid biome, the plant benefits from enhanced growth while maintaining the default biome conditions. This results in faster growth.

    • Example: A plant in a valid biome with fertilizer applied grows more quickly than normal due to the fertilizer effect.

  5. UV Light Growth: In a valid biome, UV light allows plants to grow even in dark environments, such as underground farms. The UV light modifier overrides the need for natural sunlight.

    • Example: A plant in a valid biome can grow underground with UV light, even if there is no direct sunlight access.

  6. Special Case โ€“ UV Light + Fertilizer: When both UV light and fertilizer are active in an invalid biome with no direct sunlight access, the plant enters a special growth rate, which is determined by a combination of the fertilizer_invalid_biome_growth_rate and the UVLightGrowthRate.

    • Example: A plant in an invalid biome, surrounded by darkness, grows at a combined special rate when exposed to both UV light and fertilizer.


The material name of the plant you are configuring. The specified growth modifiers will be applied to this plant. Ensure the material name matches a Minecraft name (e.g., BAMBOO, CACTUS).

For now, only official Minecraft material names listed are supported. In future updates, this will be expanded to include an API that supports custom plant materials.

This can also be an empty list if there is no fitting BiomeGroup. In such cases, the Biome list from the section is used.

If you have listed the name of a BiomeGroup under the section, you can create a new section within the section with growth modifiers specifically for the named BiomeGroup.

This section is optional. If there is no matching section for the listed BiomeGroupName, the modifiers from the section are applied to the BiomeGroupName.

The GrowthRate is set to 100%, meaning the Bamboo grows at a rate equivalent to vanilla Minecraft, maintaining the default growth speed. Additionally, if you configure the setting, Bamboo can still grow in underground farms illuminated by UV-Light Blocks (defined under ), but at a reduced growth rate of 35% compared to the normal rate.

The Default section, with its empty parentheses, signifies that Bamboo cannot grow in any other biomes outside the specified Tropical group. Thus, only the biomes listed under the BiomeGroup are considered valid for Bamboo growth.

Within the Default section, various growth parameters for Cocoa are specified, but these settings apply only to jungle biomes. The GrowthRate is set to 100%, meaning Cocoa grows at the standard rate as per vanilla Minecraft. If underground farms use UV-Light Blocks, defined under , Cocoa can still grow, but at a reduced rate of 55%.

๐Ÿ› ๏ธ
๐Ÿ“Š
Material
>here<
Default
Groups
BiomeGroup
Default
Tropical
RealisticPlantGrowth/src/main/resources/GrowthModifiers.yml at master ยท Happy-Hop7/RealisticPlantGrowthGitHub
Logo
min_natural_light
uv_blocks
uv_blocks