Fruit Trees
This document serves as a general guide for adding new fruit trees to TFG. And an explanation of class functions.
Core Mod Side
Step 1) Enum Entry
To add new Fruit Trees first locate the enum FruitTreeType and add a new enum entry following the format
java
FruitTreeType(int defaultGrowthDays, Lifecycle[] stages, int floweringLeavesColor, ResourceLocation dimension)- defaultGrowthDays: Default number of days required for growth.
- stages: Lifecycle stages is a 12-month cycle. Jan - Dec.
- floweringLeavesColor: RGB color of the leaf particles.
- dimension: The dimension this fruit tree is found in (Only information for the tooltip).
Step 2) Assets
Step 3) runData
Run runData to generate blockstate, model, and loot jsons.
Modpack Side
Step 1) Climate Range and Fruits
- Add climate range data to the constant.
- While you are in this file add fruit info to the fruit constant. This will generate jams, and other fruit related items/ recipes.
Step 2) Food Data
- Add food data to your fruit tree products.
- Add planter data for the Firmalife Greenhouse bonsai planters.
- add fruit tree constant information for generating recipes.
Step 3) Assets
- Enable GEN_JAM_MODELS and start the modpack once to generate jam models if you are adding new fruit types. Remember to set the boolean to false again before pushing.
- Add jam textures.
Step 4) Worldgen
- Create configured feature jsons for each tree like so.
- Create placed feature jsons for each tree like so.
- Add biome tags for the placed features to enable generation.
Step 5) Field Guide
- Add field guide entries for each new tree in their respective dimension category.
Tools Repo Side
- Add lang strings for everything.