The big green PR (#2694)

* blocks

* more textures

* more textures more textures

* blocks

* more textures

* more textures more textures

* blocks

* more textures

* more textures more textures

* blocks

* more textures

* more textures more textures

* firmalife gh stuff

* chloroplasts and brick regex

* gh recipes

* pisciculture fishery

* I am going insane

* more casings = more gooder

* rotten voiding cover

* greenhouse glory

* Is this it chat

* not needed

Signed-off-by: Redeix <redeix.m@gmail.com>

* missed in conflicts

Signed-off-by: Redeix <redeix.m@gmail.com>

* consumerism

* re-add tag import

* remove unused object map

* id normalizer function

---------

Signed-off-by: Redeix <redeix.m@gmail.com>
This commit is contained in:
Redeix 2026-01-10 19:30:46 -06:00 committed by GitHub
parent 3899512635
commit 900e1de8e9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
340 changed files with 3654 additions and 798 deletions

View file

@ -63,15 +63,6 @@ const registerBeneathRecipes = (event) => {
event.recipes.tfc.landslide('beneath:soul_clay', 'beneath:soul_clay')
Ingredient.of('#beneath:mushrooms').stacks.forEach(element => {
const itemId = element.id;
const recipeId = `greenhouse_${itemId.replace(':', '_')}`;
generateGreenHouseRecipe(event, element.withCount(4), '#tfc:any_fresh_water', 8000, element.withCount(24),
recipeId, 'minecraft:the_nether', 8, element.withCount(4), GTValues.VH[GTValues.LV]);
});
event.shaped('beneath:wood/sewing_table/crimson', [
' AB',
'CCC',

View file

@ -187,18 +187,6 @@ const registerFirmaLifeRecipes = (event) => {
//#region Рецепты теплиц / Greenhouse
//#region Treated Wood
event.shapeless('firmalife:treated_wood_greenhouse_port', [
'firmalife:treated_wood_greenhouse_wall',
'#forge:tiny_fluid_pipes/copper'
])
.id('firmalife:crafting/greenhouse/treated_wood_greenhouse_port')
//#endregion Treated Wood
//#region Медная / Copper
event.recipes.gtceu.extruder('tfg:firmalife/sprinkler_electric_only')
.itemInputs('#forge:plates/copper')
.notConsumable('tfg:small_casing_extruder_mold')
@ -207,233 +195,95 @@ const registerFirmaLifeRecipes = (event) => {
.EUt(8)
.addMaterialInfo(true)
// Стена
event.recipes.gtceu.shaped('8x firmalife:copper_greenhouse_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/copper',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_wall')
/**
* @type {string[]} - Tier names of greenhouse casings.
*/
const greenhouse_tiers = [
{tier: 'treated_wood', material: 'firmalife:treated_lumber'},
{tier: 'copper', material: ChemicalHelper.get(TagPrefix.rod, GTMaterials.Copper, 1)},
{tier: 'iron', material: ChemicalHelper.get(TagPrefix.rod, GTMaterials.WroughtIron, 1)},
{tier: 'stainless_steel', material: ChemicalHelper.get(TagPrefix.rod, GTMaterials.StainlessSteel, 1)}
];
// Панель
event.recipes.gtceu.shaped('8x firmalife:copper_greenhouse_panel_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/copper',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_panel_wall')
//Firmalife namespace is left so we dont have to change patchouli entries.
greenhouse_tiers.forEach(tier => {
// Панельная Крыша
event.recipes.gtceu.shaped('4x firmalife:copper_greenhouse_panel_roof', [
'A ',
'BA ',
'BBA'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/copper'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_panel_roof')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_wall`})
event.recipes.gtceu.shaped(`16x firmalife:${tier.tier}_greenhouse_wall`, [
'ABA',
'BBB',
'ABA'
], {
A: tier.material,
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_wall`)
// Крыша
event.recipes.gtceu.shaped('4x firmalife:copper_greenhouse_roof', [
'A ',
'BA ',
'BBA'
], {
A: '#forge:rods/copper',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_roof')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_panel_wall`})
event.recipes.gtceu.shaped(`16x firmalife:${tier.tier}_greenhouse_panel_wall`, [
'ABA',
'ABA',
'ABA'
], {
A: tier.material,
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_panel_wall`)
// Верхушка крыши
event.recipes.gtceu.shaped('8x firmalife:copper_greenhouse_roof_top', [
'ABA',
'BAB'
], {
A: '#forge:rods/copper',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_roof_top')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_panel_roof`})
event.recipes.gtceu.shaped(`8x firmalife:${tier.tier}_greenhouse_panel_roof`, [
'A ',
'BA ',
'BBA'
], {
A: 'firmalife:reinforced_glass',
B: tier.material
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_panel_roof`)
// Люк
event.recipes.gtceu.shaped('8x firmalife:copper_greenhouse_trapdoor', [
'ABA',
'BAB'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/copper'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_trapdoor')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_roof`})
event.recipes.gtceu.shaped(`8x firmalife:${tier.tier}_greenhouse_roof`, [
'A ',
'BA ',
'BBA'
], {
A: tier.material,
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_roof`)
// Дверь
event.recipes.gtceu.shaped('2x firmalife:copper_greenhouse_door', [
'AB',
'AB',
'AB'
], {
A: '#forge:rods/copper',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/copper_greenhouse_door')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_roof_top`})
event.recipes.gtceu.shaped(`8x firmalife:${tier.tier}_greenhouse_roof_top`, [
'ABA',
'BAB'
], {
A: tier.material,
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_roof_top`)
event.shapeless('firmalife:copper_greenhouse_port', [
'firmalife:copper_greenhouse_wall',
'#forge:tiny_fluid_pipes/copper'
])
.id('firmalife:crafting/greenhouse/copper_greenhouse_port')
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_trapdoor`})
event.recipes.gtceu.shaped(`8x firmalife:${tier.tier}_greenhouse_trapdoor`, [
'ABA',
'BAB'
], {
A: 'firmalife:reinforced_glass',
B: tier.material
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_trapdoor`)
//#endregion
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_door`})
event.recipes.gtceu.shaped(`2x firmalife:${tier.tier}_greenhouse_door`, [
'AB',
'AB',
'AB'
], {
A: tier.material,
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_door`)
//#region Железная / Iron
// Стена
event.recipes.gtceu.shaped('8x firmalife:iron_greenhouse_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/wrought_iron',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_wall')
// Панель
event.recipes.gtceu.shaped('8x firmalife:iron_greenhouse_panel_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/wrought_iron',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_panel_wall')
// Панельная Крыша
event.recipes.gtceu.shaped('4x firmalife:iron_greenhouse_panel_roof', [
'A ',
'BA ',
'BBA'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/wrought_iron'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_panel_roof')
// Крыша
event.recipes.gtceu.shaped('4x firmalife:iron_greenhouse_roof', [
'A ',
'BA ',
'BBA'
], {
A: '#forge:rods/wrought_iron',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_roof')
// Верхушка крыши
event.recipes.gtceu.shaped('8x firmalife:iron_greenhouse_roof_top', [
'ABA',
'BAB'
], {
A: '#forge:rods/wrought_iron',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_roof_top')
// Люк
event.recipes.gtceu.shaped('8x firmalife:iron_greenhouse_trapdoor', [
'ABA',
'BAB'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/wrought_iron'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_trapdoor')
// Дверь
event.recipes.gtceu.shaped('2x firmalife:iron_greenhouse_door', [
'AB',
'AB',
'AB'
], {
A: '#forge:rods/wrought_iron',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/iron_greenhouse_door')
event.shapeless('firmalife:iron_greenhouse_port', [
'firmalife:iron_greenhouse_wall',
'#forge:tiny_fluid_pipes/copper'
])
.id('firmalife:crafting/greenhouse/iron_greenhouse_port')
//#endregion
//#region Нержавеющая теплица / Stainless Steel
event.recipes.gtceu.shaped('8x firmalife:stainless_steel_greenhouse_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/stainless_steel',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_wall')
event.recipes.gtceu.shaped('8x firmalife:stainless_steel_greenhouse_panel_wall', [
'ABA',
'ABA',
'ABA'
], {
A: '#forge:rods/stainless_steel',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_panel_wall')
event.recipes.gtceu.shaped('4x firmalife:stainless_steel_greenhouse_panel_roof', [
'A ',
'BA ',
'BBA'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/stainless_steel'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_panel_roof')
event.recipes.gtceu.shaped('4x firmalife:stainless_steel_greenhouse_roof', [
'A ',
'BA ',
'BBA'
], {
A: '#forge:rods/stainless_steel',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_roof')
// Верхушка крыши
event.recipes.gtceu.shaped('8x firmalife:stainless_steel_greenhouse_roof_top', [
'ABA',
'BAB'
], {
A: '#forge:rods/stainless_steel',
B: 'firmalife:reinforced_glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_roof_top')
// Люк
event.recipes.gtceu.shaped('8x firmalife:stainless_steel_greenhouse_trapdoor', [
'ABA',
'BAB'
], {
A: 'firmalife:reinforced_glass',
B: '#forge:rods/stainless_steel'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_trapdoor')
// Дверь
event.recipes.gtceu.shaped('2x firmalife:stainless_steel_greenhouse_door', [
'AB',
'AB',
'AB'
], {
A: '#forge:rods/stainless_steel',
B: 'minecraft:glass'
}).addMaterialInfo().id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_door')
event.shapeless('firmalife:stainless_steel_greenhouse_port', [
'firmalife:stainless_steel_greenhouse_wall',
'#forge:tiny_fluid_pipes/copper'
])
.id('firmalife:crafting/greenhouse/stainless_steel_greenhouse_port')
//#endregion
event.remove({ id: `firmalife:crafting/greenhouse/${tier.tier}_greenhouse_port`})
event.recipes.gtceu.shaped(`firmalife:${tier.tier}_greenhouse_port`, [
'AB'
], {
A: `#tfg:${tier.tier}_greenhouse_casings`,
B: ChemicalHelper.get(TagPrefix.pipeTinyFluid, GTMaterials.Copper, 1)
}).addMaterialInfo().id(`firmalife:crafting/greenhouse/${tier.tier}_greenhouse_port`)
});
event.recipes.gtceu.shaped('firmalife:sweeper', [
'ABD',
@ -459,37 +309,27 @@ const registerFirmaLifeRecipes = (event) => {
//#endregion
//#region Укрепленное стекло
//#region Reinforced Glass
event.shaped('firmalife:reinforced_glass', [
event.shaped('9x firmalife:reinforced_glass', [
'AB'
], {
A: '#tfc:saws',
B: 'gtceu:tempered_glass'
}).id('tfg:shaped/reinforced_glass')
}).id('tfg:shaped/reinforced_glass');
generateCutterRecipe(event, '3x gtceu:tempered_glass', '8x firmalife:reinforced_glass', 100, 7, 'reinforced_glass')
generateCutterRecipe(event, '1x gtceu:tempered_glass', '9x firmalife:reinforced_glass', 100, 7, 'reinforced_glass');
event.recipes.gtceu.macerator('tfg:recycling/reinforced_glass')
.itemInputs('firmalife:reinforced_glass')
.itemOutputs(
ChemicalHelper.get(TagPrefix.dustTiny, GTMaterials.Glass, 1)
)
.duration(GTMaterials.Glass.getMass() * 1)
.category(GTRecipeCategories.MACERATOR_RECYCLING)
.EUt(GTValues.VA[GTValues.ULV]);
//#endregion
//#region Рецепты электрической теплицы
// Дерево
// Семена фруктов
global.FIRMALIFE_GREENHOUSE_FRUIT_RECIPE_COMPONENTS.forEach(element => {
generateGreenHouseRecipe(event, element.input, '#tfc:any_fresh_water', element.fluid_amount, element.output,
element.name, 'minecraft:overworld', 8, null, GTValues.VA[GTValues.LV])
})
// Семена ягод
global.FIRMALIFE_GREENHOUSE_BERRY_RECIPE_COMPONENTS.forEach(element => {
generateGreenHouseRecipe(event, element.input, '#tfc:any_fresh_water', element.fluid_amount, element.output,
element.name, null, 8, null, GTValues.VA[GTValues.LV])
})
//#endregion
//#region Sticky Resin by Vat
event.recipes.firmalife.vat()

View file

@ -44,6 +44,12 @@ function registerGTCEUItemTags(event) {
// @ts-expect-error According to KJS docs adding tags to tags is supported.
event.add("gtceu:molds", "#gtceu:casting_molds", "#gtceu:extruder_molds", "gtceu:empty_mold");
// Groups up concrete blocks into tags.
Object.entries(global.GTCEU_CONCRETE_BLOCKS).forEach(([type, ids]) => {
event.add(`tfg:gtceu_concrete_blocks/${type}`, ids);
event.add('tfg:gtceu_concrete_blocks', ids);
});
//greens
event.add('tfc:compost_greens', 'gtceu:bio_chaff');
event.add('tfc:compost_greens', 'gtceu:plant_ball');
@ -85,6 +91,12 @@ function registerGTCEUBlockTags(event) {
event.add("gtceu:cleanroom_doors", "ad_astra:desh_sliding_door");
event.add("gtceu:cleanroom_doors", "ad_astra:ostrum_sliding_door");
event.add("gtceu:cleanroom_doors", "ad_astra:calorite_sliding_door");
// Groups up concrete blocks into tags.
Object.entries(global.GTCEU_CONCRETE_BLOCKS).forEach(([type, ids]) => {
event.add(`tfg:gtceu_concrete_blocks/${type}`, ids);
event.add('tfg:gtceu_concrete_blocks', ids);
});
}
/** @param {TagEvent.Fluid} event */

View file

@ -66,64 +66,6 @@ const generateCutterRecipe = (event, input, output, duration, EUt, id) => {
//#endregion
//#region Green House
/**
* Function for generating greenhouse recipes.
*
* @param {*} event
* @param {string} input -Item (Not consumed)
* @param {string} fluid -Fluid ID or tag
* @param {number} fluid_amount -Fluid amount, in mB
* @param {string} output -Item (Chanced output uses input item)
* @param {string} id -Recipe ID
* @param {string} dimension -Dimension ID
* @param {number} fertiliser_count
* @param {string|null} output_seconday -Item (Optional, if there should be a third output)
* @param {number} EUt
*/
function generateGreenHouseRecipe(event, input, fluid, fluid_amount, output, id, dimension, fertiliser_count, output_secondary, EUt) {
if (EUt === undefined || output_secondary === undefined || fertiliser_count === undefined || dimension === undefined) {
throw new TypeError(`Call to generateGreenHouseRecipe for id ${id} is missing args`);
}
let r = event.recipes.gtceu.greenhouse(id)
.notConsumable(input)
.circuit(1)
.inputFluids(`${fluid} ${fluid_amount}`)
.itemOutputs(output)
.chancedOutput(input, 750, 0)
.chancedOutput(input, 500, 0)
.duration(36000) // 30 mins
.EUt(EUt)
if (dimension !== null) {
r.dimension(dimension)
}
if (output_secondary !== null) {
r.chancedOutput(output_secondary, 750, 0)
}
// С удобрением (With fertilizer)
r = event.recipes.gtceu.greenhouse(`${id}_fertilized`)
.notConsumable(input)
.itemInputs(Item.of('gtceu:fertilizer', fertiliser_count))
.circuit(2)
.inputFluids(`${fluid} ${fluid_amount}`)
.itemOutputs(output)
.chancedOutput(input, 4000, 0)
.chancedOutput(input, 3000, 0)
.duration(12000) // 10 mins
.EUt(EUt)
if (dimension !== null) {
r.dimension(dimension)
}
if (output_secondary !== null) {
r.chancedOutput(output_secondary, 4000, 0)
}
}
//#endregion
//#region Filling NBT
/**
* Function to get fluid filling NBT.

View file

@ -533,7 +533,7 @@ const registerMinecraftRecipes = (event) => {
A: '#forge:plates/wrought_iron',
B: '#forge:chests/wooden',
D: '#forge:tools/wrenches',
E: '#forge:tools/hammers',
E: '#forge:tools/hammers'
}).id('gtceu:shaped/hopper')
event.recipes.gtceu.assembler('hopper_wrought_iron')
@ -896,7 +896,7 @@ const registerMinecraftRecipes = (event) => {
A: '#forge:rods/black_steel',
B: 'minecraft:lava_bucket',
C: '#minecraft:logs',
D: '#forge:storage_blocks/charcoal',
D: '#forge:storage_blocks/charcoal'
}).id('tfg:campfire_charcoal')
event.shaped('minecraft:campfire', [
@ -907,7 +907,7 @@ const registerMinecraftRecipes = (event) => {
A: '#forge:rods/black_steel',
B: 'minecraft:lava_bucket',
C: '#minecraft:logs',
D: '#forge:storage_blocks/coal',
D: '#forge:storage_blocks/coal'
}).id('tfg:campfire_coal')
//#endregion
@ -1053,22 +1053,6 @@ const registerMinecraftRecipes = (event) => {
// #endregion
//#region Greenhouse
generateGreenHouseRecipe(event, '8x minecraft:bamboo', '#tfc:any_fresh_water', 4000,
'64x minecraft:bamboo', 'bamboo', 'minecraft:overworld', 8,
'8x minecraft:bamboo', GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '4x minecraft:red_mushroom', '#tfc:any_fresh_water', 4000,
'24x minecraft:red_mushroom', 'red_mushroom', 'minecraft:the_nether', 8,
'4x minecraft:red_mushroom', GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '4x minecraft:brown_mushroom', '#tfc:any_fresh_water', 4000,
'24x minecraft:brown_mushroom', 'brown_mushroom', 'minecraft:the_nether', 8,
'4x minecraft:brown_mushroom', GTValues.VA[GTValues.LV])
// #endregion
// Minecart w/ Furnace
event.shapeless('minecraft:furnace_minecart', ['minecraft:water_bucket', 'gtceu:hp_steam_solid_boiler', 'minecraft:minecart']);

View file

@ -57,50 +57,6 @@ const registerTFCRecipes = (event) => {
event.recipes.tfc.quern(element.output, element.input)
.id(`tfg:quern/${element.name}`)
})
//#region Рецепты электрической теплицы
// Дерево
global.TFC_WOOD_TYPES.forEach(wood => {
generateGreenHouseRecipe(event, `8x tfc:wood/sapling/${wood}`, '#tfc:any_fresh_water', 16000, `64x tfc:wood/log/${wood}`,
`tfg:greenhouse/${wood}`, 'minecraft:overworld', 16, `32x tfc:wood/sapling/${wood}`, GTValues.VH[GTValues.LV])
})
global.AFC_SAPLINGS.forEach(x => {
generateGreenHouseRecipe(event, `8x afc:wood/sapling/${x.sapling}`, '#tfc:any_fresh_water', 16000, `64x ${x.log}`,
`tfg:greenhouse/${x.sapling}`, 'minecraft:overworld', 16, `32x afc:wood/sapling/${x.sapling}`, GTValues.VH[GTValues.LV])
})
// Семена фруктов
global.TFC_GREENHOUSE_FRUIT_RECIPE_COMPONENTS.forEach(element => {
generateGreenHouseRecipe(event, element.input, '#tfc:any_fresh_water', element.fluid_amount, element.output,
element.name, 'minecraft:overworld', 8, element.input, GTValues.VH[GTValues.LV])
})
// Семена овощей
global.TFC_GREENHOUSE_VEGETABLE_RECIPE_COMPONENTS.forEach(element => {
generateGreenHouseRecipe(event, element.input, '#tfc:any_fresh_water', element.fluid_amount, element.output,
element.name, null, 8, element.input, GTValues.VH[GTValues.LV])
})
// Семена ягод
global.TFC_GREENHOUSE_BERRY_RECIPE_COMPONENTS.forEach(element => {
generateGreenHouseRecipe(event, element.input, '#tfc:any_fresh_water', element.fluid_amount, element.output,
element.name, null, 8, element.input, GTValues.VH[GTValues.LV])
})
// Растения
Ingredient.of('#tfc:plants').subtract('#tfc:wild_fruits').stacks.forEach(element => {
const itemId = element.id;
const recipeId = `greenhouse_${itemId.replace(':', '_')}`;
generateGreenHouseRecipe(event, itemId, '#tfc:any_fresh_water', 8000, `8x ${itemId}`,
recipeId, null, 8, itemId, GTValues.VH[GTValues.LV]);
});
//#endregion
// Доменная печь
event.recipes.gtceu.shaped('tfc:blast_furnace', [
'AAA',

View file

@ -1,6 +1,8 @@
// priority: 0
"use strict";
const ForgeRegistries = Java.loadClass('net.minecraftforge.registries.ForgeRegistries');
/** @param {TagEvent.Item} event */
function registerTFCItemTags(event) {
// Теги для соответствия инструментов TFC и GT
@ -511,11 +513,21 @@ function registerTFCBlockTags(event) {
event.add("tfc:forge_invisible_whitelist", "greate:stainless_steel_mechanical_pump");
event.add("tfc:forge_invisible_whitelist", "greate:titanium_mechanical_pump");
//Allows any block with the word "brick" in its id to be used as bloomery and forge insulation.
//Add blacklisted words to the const with | between.
const brick_blacklist = "drying|slab|stairs|wall|additionalplacements";
event.add("tfc:bloomery_insulation", `/^(?=.*brick)(?!.*(${brick_blacklist})).*/`);
event.add("tfc:forge_insulation", `/^(?=.*brick)(?!.*(${brick_blacklist})).*/`);
// Allows any block with the word "brick" in its id to be used as bloomery and forge insulation.
// Optimized to compute matching blocks once instead of regex scanning per tag like before.
// Blacklist removes blocks that are unwanted.
const blacklist = ["drying", "slab", "stairs", "wall", "additionalplacements", "fence", "roof", "bridge"];
const matches = [];
ForgeRegistries.BLOCKS.getValues().forEach(block => {
const id = String(ForgeRegistries.BLOCKS.getKey(block));
if (id.includes("brick") && !blacklist.some(no_no_word => id.includes(no_no_word))) {
matches.push(id);
};
});
["tfc:bloomery_insulation", "tfc:forge_insulation"].forEach(tag => {
matches.forEach(id => event.add(tag, id));
});
event.add("tfc:forge_insulation", 'create:depot');
global.TFC_STONE_TYPES.forEach((stone) => {

View file

@ -0,0 +1,15 @@
"use strict";
/** @param {Internal.TFCDataEventJS} event */
function registerTFGAquaponicsData(event) {
event.fuel('tfg:flora_pellets', 1415, 1900, 0.95);
event.foodItem('tfg:fish_roe', (food) => {
food.hunger(4);
food.decayModifier(2);
food.protein(2.5);
food.saturation(2);
});
}

View file

@ -0,0 +1,555 @@
// priority: 1
"use strict";
///////////////////////////////////////////////////////////////////////////////////////////////////////
//#region Balancing Values
/** Base duration of recipes in ticks. */
const greenhouse_base_duration = 16 * 60 * 20;
/** Duration multiplier for fertilized recipes. */
const greenhouse_duration_multiplier_fertilized = 0.5;
/** Duration multiplier for aquaponic recipes. */
const greenhouse_duration_multiplier_aquaponics = 0.4;
/** Hydroponic facility chance multiplier. */
const hydroponics_facility_chance_multiplier = 1.25;
/** Base percent chance for chanced outputs (out of 100). */
const greenhouse_chanced_output_base = 7.5;
/** Fertilized percent chance for chanced outputs (out of 100). */
const greenhouse_chanced_output_fertilized = 40;
/** Aquaponics percent chance for chanced outputs (out of 100). */
const greenhouse_chanced_output_aquaponics = 80;
/**
* Dimension setting index provides recipe modifications based on the dimension assigned.
*
* @typedef {Object} DimensionIndex
* @property {Internal.Dimension} id - Dimension ID.
* @property {Internal.FluidStackIngredient_} fluid - Fluid ID or tag.
* @property {number} fluid_chance - Chance for fluid consumption per tick out of 100.
* @property {Internal.ItemStack|null} fertilizer - Fertilizer item ID or null if fertilizer is not needed on that dimension.
* @property {GTValues.EUt} eut - EUt value for that dimension.
* @property {boolean|null} oxygenated - Whether the recipe requires an oxygenated environment.
*/
/** @param {...DimensionIndex[]} - Dimension settings array */
const greenhouse_dimension_index = [
// Overworld settings are also used as the default when no dimension is specified.
{id: 'minecraft:overworld', fluid: '#tfg:clean_water', fluid_tier2: 'tfg:nitrate_rich_water', fluid_chance: 10, fertilizer: 'gtceu:fertilizer', eut: GTValues.VA[GTValues.LV], oxygenated: true},
{id: 'minecraft:the_nether', fluid: '#tfg:clean_water', fluid_tier2: 'tfg:nitrate_rich_water', fluid_chance: 10, fertilizer: 'gtceu:fertilizer', eut: GTValues.VA[GTValues.LV], oxygenated: true},
{id: 'ad_astra:moon', fluid: 'gtceu:helium_3', fluid_tier2: null, fluid_chance: 2, fertilizer: null, eut: GTValues.VA[GTValues.MV], oxygenated: null},
{id: 'ad_astra:mars', fluid: 'tfg:semiheavy_ammoniacal_water', fluid_tier2: 'tfg:nitrate_rich_semiheavy_ammoniacal_water', fluid_chance: 10, fertilizer: 'gtceu:fertilizer', eut: GTValues.VA[GTValues.HV], oxygenated: null}
];
//#endregion
///////////////////////////////////////////////////////////////////////////////////////////////////////
//#region Utility Script
/** Correct recipe IDs to replace invalid characters */
function linuxUnfucker(value) {
const str = (value === undefined || value === null) ? "" : value.toString();
return str.replace(/[/:\s]/g, "_");
};
/**
* Function for generating greenhouse recipes.
*
* @param {*} event
* @param {Internal.Dimension|null} dimension -Dimension ID
* @param {Internal.ItemStack} input -Input Item (seeds, saplings, etc.)
* @param {Internal.ItemStack|Internal.ItemStack[]} output -Output Items. If array, first item is guaranteed while rest use chanced output. Last item in array is used for the rest of the chance outputs.
* @param {number|null} chance_multiplier -Multiplies output chances by this value. Defaults to 1.
*/
function generateGreenHouseRecipe(event, dimension, input, output, chance_multiplier) {
// Resolve dimension based modifier defaults by comparing to the `greenhouse_dimension_index` array.
/** @type {DimensionIndex|null} */
const dimMods = dimension ? greenhouse_dimension_index.find(d => d.id === dimension) : null;
/** @type {Internal.FluidStackIngredient_} - Resolved fluid ID or tag. Defaults to `#tfg:clean_water` */
const resolvedFluid = dimMods?.fluid ?? '#tfg:clean_water';
/** @type {Internal.FluidStackIngredient_} - Resolved aquaponic loop fluid ID or tag. Defaults to `tfg:nitrate_rich_water` */
const resolvedFluidTier2 = dimMods?.fluid_tier2 ?? 'tfg:nitrate_rich_water';
/** @type {Internal.ItemStack|null} - Resolved fertilizer item ID. Defaults to `gtceu:fertilizer` */
const resolvedFertilizer = dimMods ? dimMods.fertilizer : 'gtceu:fertilizer';
/** @type {boolean} - Whether fertilization is possible for this dimension. */
const canFertilize = resolvedFertilizer !== null;
/** @type {GTValues.EUt} - Resolved EUt value. Defaults to LV */
const resolvedEUt = dimMods ? dimMods.eut : GTValues.VA[GTValues.LV];
/** @type {number} - Resolved fluid chance multiplied by 100. Defaults to 1000. */
const resolvedChance = dimMods ? (dimMods.fluid_chance * 100) : 1000;
/** @type {boolean|null} - Whether the recipe requires an oxygenated environment. Defaults to true. */
const requiresOxygen = dimMods ? dimMods.oxygenated : true;
/////////////////////////////////////////////////////////////////////////////////////////////////////
/** Collect errors. */
const errors = [];
if (input === undefined || Array.isArray(input)) {
errors.push("input is undefined or is an array");
};
if (output !== undefined && !Array.isArray(output)) {
output = [output];
}
if (output === undefined || output.length === 0 || output.length > 4) {
errors.push("output is undefined or has invalid length");
};
// If there are any errors, log them all and throw once.
if (errors.length > 0) {
throw new TypeError(`Greenhouse recipe errors for recipe ID ${`tfg:greenhouse/${linuxUnfucker(input)}`}\n - ${errors.join("\n - ")}`);
};
////////////////////////////////////////////////////////////////////////////////////////////////////////
// Normalize outputs to an array of 4 items.
// index 0 is guaranteed output, indexes 1-3 are chanced outputs.
// Last item in output array is used for any missing chanced outputs.
let outputs_array = [];
const guaranteed_output = output[0];
const last_output = output[output.length - 1];
for (let i = 0; i < 4; i++) {
if (i === 0) outputs_array[i] = guaranteed_output;
else outputs_array[i] = (output[i] !== undefined) ? output[i] : last_output;
};
////////////////////////////////////////////////////////////////////////////////////////////////////////
// Math Section :D
/**
* Function to keep calculated duration values above 0 (minimum 1 tick).
*
* @param {number} value - Number to validate.
* @returns {number} - Validated Number.
*/
function validate_duration(value) {
return Math.max(1, Math.round(value));
};
const fertilizer_duration = validate_duration(greenhouse_base_duration * greenhouse_duration_multiplier_fertilized);
const aquaponic_duration = validate_duration(greenhouse_base_duration * greenhouse_duration_multiplier_aquaponics);
/**
* Function to keep percent values within valid range (1 to 10000).
*
* @param {number} value - Number to validate.
* @returns {number} - Validated Number.
*/
function validate_percent(value) {
return Math.min(10000, Math.max(1, Math.round(value)));
};
chance_multiplier = chance_multiplier ?? 1;
chance_multiplier = chance_multiplier * 100;
const base_chance = validate_percent(greenhouse_chanced_output_base * chance_multiplier);
const fertilizer_chance = validate_percent(greenhouse_chanced_output_fertilized * chance_multiplier);
const aquaponic_chance = validate_percent(greenhouse_chanced_output_aquaponics * chance_multiplier);
const hydroponics_base_chance = validate_percent(greenhouse_chanced_output_base * chance_multiplier);
const hydroponics_fertilizer_chance = validate_percent(greenhouse_chanced_output_fertilized * chance_multiplier * hydroponics_facility_chance_multiplier);
const hydroponics_aquaponic_chance = validate_percent(greenhouse_chanced_output_aquaponics * chance_multiplier * hydroponics_facility_chance_multiplier);
////////////////////////////////////////////////////////////////////////////////////////////////////////
// Recipe Scripts.
if (canFertilize) {
//======================== Greenhouse Recipes ========================
// Base recipe.
let a = event.recipes.gtceu.greenhouse(`tfg:${linuxUnfucker(input)}`)
.notConsumable(input)
.circuit(1)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(greenhouse_base_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
a.dimension(dimension)
};
if (requiresOxygen !== null) {
TFGRecipeSchemaBindings.isOxygenated(a, requiresOxygen)
};
if (outputs_array[1] !== null) {
a.chancedOutput(outputs_array[1], base_chance, 0)
a.chancedOutput(outputs_array[2], base_chance, 0)
a.chancedOutput(outputs_array[3], base_chance, 0)
};
// Fertilized Recipe.
let b = event.recipes.gtceu.greenhouse(`tfg:${linuxUnfucker(input)}_fertilized`)
.notConsumable(input)
.circuit(2)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(fertilizer_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
b.dimension(dimension)
};
if (requiresOxygen !== null) {
TFGRecipeSchemaBindings.isOxygenated(b, requiresOxygen)
};
if (outputs_array[1] !== null) {
b.chancedOutput(outputs_array[1], fertilizer_chance, 0)
b.chancedOutput(outputs_array[2], fertilizer_chance, 0)
b.chancedOutput(outputs_array[3], fertilizer_chance, 0)
b.itemInputs(Item.of(resolvedFertilizer, 8))
};
// Aquaponics Recipe.
let c = event.recipes.gtceu.greenhouse(`tfg:${linuxUnfucker(input)}_aquaponic`)
.notConsumable(input)
.circuit(3)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluidTier2} 1`, resolvedChance, 0)
.perTick(false)
.duration(aquaponic_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
c.dimension(dimension)
};
if (requiresOxygen !== null) {
TFGRecipeSchemaBindings.isOxygenated(c, requiresOxygen)
};
if (outputs_array[1] !== null) {
c.chancedOutput(outputs_array[1], aquaponic_chance, 0)
c.chancedOutput(outputs_array[2], aquaponic_chance, 0)
c.chancedOutput(outputs_array[3], aquaponic_chance, 0)
};
c.itemOutputs('tfg:flora_pellets');
//======================== Hydroponic Facility Recipes ========================
// Base recipe.
let d = event.recipes.gtceu.hydroponics_facility(`tfg:${linuxUnfucker(input)}`)
.notConsumable(input)
.circuit(1)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(greenhouse_base_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
d.dimension(dimension)
};
if (outputs_array[1] !== null) {
d.chancedOutput(outputs_array[1], hydroponics_base_chance, 0)
d.chancedOutput(outputs_array[2], hydroponics_base_chance, 0)
d.chancedOutput(outputs_array[3], hydroponics_base_chance, 0)
};
// Fertilized Recipe.
let e = event.recipes.gtceu.hydroponics_facility(`tfg:${linuxUnfucker(input)}_fertilized`)
.notConsumable(input)
.circuit(2)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(fertilizer_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
e.dimension(dimension)
};
if (outputs_array[1] !== null) {
e.chancedOutput(outputs_array[1], hydroponics_fertilizer_chance, 0)
e.chancedOutput(outputs_array[2], hydroponics_fertilizer_chance, 0)
e.chancedOutput(outputs_array[3], hydroponics_fertilizer_chance, 0)
e.itemInputs(Item.of(resolvedFertilizer, 8))
};
// Aquaponics Recipe.
let f = event.recipes.gtceu.hydroponics_facility(`tfg:${linuxUnfucker(input)}_aquaponic`)
.notConsumable(input)
.circuit(3)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluidTier2} 1`, resolvedChance, 0)
.perTick(false)
.duration(aquaponic_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
f.dimension(dimension)
};
if (outputs_array[1] !== null) {
f.chancedOutput(outputs_array[1], hydroponics_aquaponic_chance, 0)
f.chancedOutput(outputs_array[2], hydroponics_aquaponic_chance, 0)
f.chancedOutput(outputs_array[3], hydroponics_aquaponic_chance, 0)
};
f.itemOutputs('tfg:flora_pellets');
} else {
// Base recipe boosted if no fertilization needed.
//======================== Greenhouse Recipes ========================
let a = event.recipes.gtceu.greenhouse(`tfg:${linuxUnfucker(input)}`)
.notConsumable(input)
.circuit(1)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(fertilizer_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
a.dimension(dimension)
};
if (requiresOxygen !== null) {
TFGRecipeSchemaBindings.isOxygenated(a, requiresOxygen)
};
if (outputs_array[1] !== null) {
a.chancedOutput(outputs_array[1], fertilizer_chance, 0)
a.chancedOutput(outputs_array[2], fertilizer_chance, 0)
a.chancedOutput(outputs_array[3], fertilizer_chance, 0)
};
//======================== Hydroponics Facility Recipes ========================
let b = event.recipes.gtceu.hydroponics_facility(`tfg:${linuxUnfucker(input)}`)
.notConsumable(input)
.circuit(1)
.itemOutputs(outputs_array[0])
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.perTick(false)
.duration(fertilizer_duration)
.EUt(resolvedEUt)
if (dimension !== null) {
b.dimension(dimension)
};
if (outputs_array[1] !== null) {
b.chancedOutput(outputs_array[1], hydroponics_fertilizer_chance, 0)
b.chancedOutput(outputs_array[2], hydroponics_fertilizer_chance, 0)
b.chancedOutput(outputs_array[3], hydroponics_fertilizer_chance, 0)
};
};
};
/**
* Function for generating standard crop greenhouse recipes.
* Uses the following defaults:
* - 4x seed inputs
* - 20x crop output
* - 1x seed chanced output
* - 4x crop chanced output
*
* @param {Internal.RecipesEventJS} event
* @param {Internal.Dimension|null} dimension -Dimension ID
* @param {Internal.Ingredient} input -Input Item. (seed, bush, etc.)
* @param {Internal.ItemStack} output -Output Item. (vegetable, fruit, etc.)
* @param {number|null} chance_multiplier -Multiplies output chances by this value. Defaults to 1.
*/
function generateCropGreenHouseRecipe(event, dimension, input, output, chance_multiplier) {
generateGreenHouseRecipe(event, dimension, `4x ${input}`, [Item.of(output, 20), Item.of(input, 1), Item.of(output, 4)], chance_multiplier);
};
/**
* Function for generating standard tree greenhouse recipes.
* Uses the following defaults:
* - 8x sapling inputs
* - 64x wood output
* - 4x sapling chanced output
* - 16x wood chanced output
*
* @param {Internal.RecipesEventJS} event
* @param {Internal.Dimension|null} dimension -Dimension ID
* @param {Internal.Ingredient} input -Input Item. (sapling)
* @param {Internal.ItemStack} output -Output Item. (wood)
* @param {number|null} chance_multiplier -Multiplies output chances by this value. Defaults to 1.
*/
function generateTreeGreenHouseRecipe(event, dimension, input, output, chance_multiplier) {
generateGreenHouseRecipe(event, dimension, `8x ${input}`, [Item.of(output, 64), Item.of(input, 4), Item.of(output, 16)], chance_multiplier);
};
//#endregion
// Recipes
/**
* @param {Internal.RecipesEventJS} event
*/
const registerTFGGreenhouseRecipes = (event) => {
//#region Multiblock Parts
/** @type {string[]} - Tier names of greenhouse casings. */
const greenhouse_tiers = ['treated_wood', 'copper', 'iron', 'stainless_steel'];
greenhouse_tiers.forEach(tier => {
const tier_tag = Ingredient.of(`#tfg:${tier}_greenhouse_casings`).itemIds.toArray().map(String);
tier_tag.forEach(item => {
event.stonecutting(item,
Ingredient.of(`#tfg:${tier}_greenhouse_casings`).subtract(item)
).id(`tfg:stonecutter/${linuxUnfucker(item)}`)
});
});
// Cultivation Monitor
event.recipes.gtceu.shaped('tfg:cultivation_monitor', [
'CEC',
'DBD',
'CAC'
], {
A: 'gtceu:ev_scanner',
B: 'gtceu:computer_monitor_cover',
C: ChemicalHelper.get(TagPrefix.plateDense, GTMaterials.TungstenSteel, 1),
D: '#gtceu:circuits/luv',
E: '#forge:lenses/emerald'
}).addMaterialInfo().id('tfg:shaped/cultivation_monitor');
// Hydroponics Facility Controller
event.recipes.gtceu.shaped('tfg:hydroponics_facility', [
'FBF',
'EAE',
'CDC'
], {
A: 'gtceu:iv_machine_hull',
B: 'tfg:cultivation_monitor',
C: '#gtceu:circuits/iv',
D: 'gtceu:platinum_single_cable',
E: 'gtceu:iv_electric_pump',
F: 'tfg:grow_light'
}).addMaterialInfo().id('tfg:shaped/hydroponics_facility');
// Grow Lights
event.recipes.gtceu.shaped('2x tfg:grow_light', [
'ABA',
'CDC'
], {
A: ChemicalHelper.get(TagPrefix.plate, GTMaterials.TinAlloy, 1),
B: 'gtceu:annealed_copper_single_cable',
C: 'minecraft:glowstone',
D: 'gtceu:tin_alloy_small_fluid_pipe'
}).addMaterialInfo().id('tfg:shaped/grow_light');
// Horticulture Planters
event.recipes.gtceu.shaped('tfg:egh_planter', [
'BAB',
'BDB',
'CCC'
], {
A: 'firmalife:hydroponic_planter',
B: ChemicalHelper.get(TagPrefix.plate, GTMaterials.TungstenSteel, 1),
C: 'tfg:grow_light',
D: 'gtceu:iv_hermetic_casing'
}).addMaterialInfo().id('tfg:shaped/egh_planter');
// Horticulture Casings
event.recipes.gtceu.assembler('tfg:casings/machine_casing_egh')
.itemInputs('gtceu:plascrete', '#forge:frames/calorite')
.inputFluids(Fluid.of('tfg:chloroplasts', 100))
.itemOutputs('2x tfg:casings/machine_casing_egh')
.duration(8*20)
.circuit(6)
.EUt(GTValues.VA[GTValues.HV])
.addMaterialInfo(true);
//#endregion
//#region Recipes
// Mushrooms
Ingredient.of('#beneath:mushrooms').stacks.forEach(element => {
generateGreenHouseRecipe(event, 'minecraft:the_nether', `8x ${element.id}`, [element.withCount(24), element.withCount(8)], 1);
});
generateGreenHouseRecipe(event, 'minecraft:the_nether', '8x minecraft:red_mushroom', ['24x minecraft:red_mushroom', '8x minecraft:red_mushroom'], 1);
generateGreenHouseRecipe(event, 'minecraft:the_nether', '8x minecraft:brown_mushroom', ['24x minecraft:brown_mushroom', '8x minecraft:brown_mushroom'], 1);
// Crops
global.FIRMALIFE_GREENHOUSE_FRUIT_RECIPE_COMPONENTS.forEach(element => {
generateCropGreenHouseRecipe(event, null, element.input, element.output, 1);
});
global.TFC_GREENHOUSE_FRUIT_RECIPE_COMPONENTS.forEach(element => {
generateCropGreenHouseRecipe(event, null, element.input, element.output, 1);
});
global.TFC_GREENHOUSE_VEGETABLE_RECIPE_COMPONENTS.forEach(element => {
generateCropGreenHouseRecipe(event, null, element.input, element.output, 1);
});
global.TFC_GREENHOUSE_BERRY_RECIPE_COMPONENTS.forEach(element => {
generateCropGreenHouseRecipe(event, null, element.input, element.output, 1);
});
// Wood
global.TFC_WOOD_TYPES.forEach(element => {
generateTreeGreenHouseRecipe(event, null, `tfc:wood/sapling/${element}`, `tfc:wood/log/${element}`, 1);
});
global.AFC_SAPLINGS.forEach(element => {
generateTreeGreenHouseRecipe(event, null, `afc:wood/sapling/${element.sapling}`, element.log, 1);
});
// Plants
Ingredient.of('#tfc:plants').subtract('#tfc:wild_fruits').stacks.forEach(element => {
generateGreenHouseRecipe(event, null, `8x ${element.id}`, [element.withCount(24), element.withCount(8)], 1);
});
generateGreenHouseRecipe(event, null, '8x minecraft:bamboo', ['64x minecraft:bamboo', '8x minecraft:bamboo'], 1);
// Mars Wood
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/strophar', [
'64x ad_astra:strophar_stem', '4x tfg:saplings/strophar', '16x ad_astra:strophar_cap', '16x ad_astra:strophar_cap'
], 1);
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/aeronos', [
'64x ad_astra:aeronos_stem', '4x tfg:saplings/aeronos', '16x ad_astra:aeronos_cap', '16x ad_astra:aeronos_cap'
], 1);
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/glacian', [
'64x ad_astra:glacian_log', '4x tfg:saplings/glacian', '16x species:alphacene_moss_block', '16x species:alphacene_moss_block'
], 1);
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/alphacene', [
'64x species:alphacene_mushroom_block', '4x tfg:saplings/alphacene', '16x minecraft:mushroom_stem', '16x minecraft:mushroom_stem'
], 1);
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/warped', [
'64x beneath:wood/log/warped', '4x tfg:saplings/warped', '16x minecraft:warped_wart_block', '16x minecraft:warped_wart_block'
], 1);
generateGreenHouseRecipe(event, 'ad_astra:mars', '8x tfg:saplings/crimson', [
'64x beneath:wood/log/crimson', '4x tfg:saplings/crimson', '16x minecraft:nether_wart_block', '16x minecraft:nether_wart_block'
], 1);
// Mars Plants
Ingredient.of('#tfg:mars_plants').stacks.forEach(element => {
generateGreenHouseRecipe(event, 'ad_astra:mars', `8x ${element.id}`, [element.withCount(24), element.withCount(8)], 1);
});
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:amber_root_seeds', 'betterend:amber_root_product', 1);
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:blossom_berry_seeds', 'betterend:blossom_berry_product', 1);
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:bolux_mushroom_seeds', 'betterend:bolux_mushroom_product', 1);
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:cave_pumpkin_plant_seeds', 'betterend:cave_pumpkin', 1);
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:chorus_mushroom_seeds', 'betterend:chorus_mushroom_product', 1);
generateCropGreenHouseRecipe(event, 'ad_astra:mars', 'betterend:shadow_berry_seeds', 'betterend:shadow_berry_product', 1);
// Moon Crops
generateCropGreenHouseRecipe(event, 'ad_astra:moon', 'tfg:lunar_chorus_flower', 'minecraft:chorus_fruit', 2);
// Moon Plants
generateGreenHouseRecipe(event, 'ad_astra:moon', '8x minecraft:twisting_vines', [
'16x minecraft:twisting_vines', '8x minecraft:pearlescent_froglight', '8x minecraft:verdant_froglight', '8x minecraft:ochre_froglight'
], 1);
Ingredient.of('#tfg:moon_plants').stacks.forEach(element => {
generateGreenHouseRecipe(event, 'ad_astra:moon', `8x ${element.id}`, [element.withCount(24), element.withCount(8)], 1);
});
//#endregion
};

View file

@ -0,0 +1,242 @@
// priority: 0
"use strict";
///////////////////////////////////////////////////////////////////////////////////////////////////////
//#region Balancing Values
/**
* Base duration of recipes in ticks.
* * Should match the Greenhouse base duration * aquaponics multiplier.
*/
const pisciculture_base_duration = Math.max(1, greenhouse_base_duration * greenhouse_duration_multiplier_aquaponics);
/**
* Dimension setting index provides recipe modifications based on the dimension assigned.
*
* @typedef {Object} DimensionIndex
* @property {Internal.Dimension} id - Dimension ID.
* @property {Internal.FluidStackIngredient_} fluid - Fluid ID or tag.
* @property {number} fluid_chance - Chance for fluid consumption per tick out of 100.
* @property {Internal.FluidStackIngredient_} fluid_out - Output fluid ID.
* @property {GTValues.EUt} eut - EUt value for that dimension.
* @property {boolean|null} oxygenated - Whether the recipe requires an oxygenated environment.
*/
/** @type {DimensionIndex[]} - Dimension settings array */
const pisciculture_dimension_index = [
// Overworld settings are also used as the default when no dimension is specified.
{id: 'minecraft:overworld', fluid: '#tfg:clean_water', fluid_chance: 50, fluid_out: 'tfg:nitrate_rich_water', eut: GTValues.VA[GTValues.LV], oxygenated: true},
{id: 'minecraft:the_nether', fluid: '#tfg:clean_water', fluid_chance: 50, fluid_out: 'tfg:nitrate_rich_water', eut: GTValues.VA[GTValues.LV], oxygenated: true},
// The moon has no fish yet :(
{id: 'ad_astra:mars', fluid: 'tfg:semiheavy_ammoniacal_water', fluid_chance: 50, fluid_out: 'tfg:nitrate_rich_semiheavy_ammoniacal_water', eut: GTValues.VA[GTValues.HV], oxygenated: null}
];
//#endregion
///////////////////////////////////////////////////////////////////////////////////////////////////////
//#region Utility Script
/**
* Function for generating pisciculture recipes.
*
* @param {*} event
* @param {Internal.Dimension|null} dimension -Dimension ID.
* @param {Internal.ItemStack|Internal.ItemStack[]} input -Input Item (roe, fish food, etc).
* @param {Internal.ItemStack|Internal.ItemStack[]} output -Output Items.
* @param {string} id -Recipe ID.
*/
function generatePiscicultureRecipe(event, dimension, input, output, id) {
// Resolve dimension based modifier defaults by comparing to the `pisciculture_dimension_index` array.
const dimMods = dimension ? pisciculture_dimension_index.find(d => d.id === dimension) : null;
const resolvedFluid = dimMods?.fluid ?? '#tfg:clean_water';
const resolvedFluidOut = dimMods?.fluid_out ?? 'tfg:nitrate_rich_water';
const resolvedEUt = dimMods ? dimMods.eut : GTValues.VA[GTValues.LV];
const resolvedChance = dimMods ? (dimMods.fluid_chance * 100) : 5000;
const requiresOxygen = dimMods ? dimMods.oxygenated : true;
// Collect errors.
const errors = [];
if (input === undefined) {
errors.push("input is undefined");
};
if (output !== undefined && !Array.isArray(output)) {
output = [output];
}
if (output === undefined || output.length === 0 || output.length > 4) {
errors.push("output is undefined or has invalid length");
};
// If there are any errors, log them all and throw once.
if (errors.length > 0) {
throw new TypeError(`Pisciculture Fishery recipe errors for recipe ID ${`tfg:pisciculture_fishery/${id}`}\n - ${errors.join("\n - ")}`);
};
let a = event.recipes.gtceu.pisciculture_fishery(`tfg:${id}`)
.itemInputs(input)
.perTick(true)
.chancedFluidInput(`${resolvedFluid} 1`, resolvedChance, 0)
.chancedFluidOutput(`${resolvedFluidOut} 1`, resolvedChance, 0)
.perTick(false)
.itemOutputs(output)
.duration(pisciculture_base_duration)
.EUt(resolvedEUt);
if (dimension !== null) {
a.dimension(dimension)
};
if (requiresOxygen !== null) {
TFGRecipeSchemaBindings.isOxygenated(a, requiresOxygen)
};
};
//#endregion
/**
* @param {Internal.RecipesEventJS} event
*/
const registerTFGPiscicultureRecipes = (event) => {
//#region Multiblock Parts
// Pisciculture Fishery Controller
event.recipes.gtceu.shaped('tfg:pisciculture_fishery', [
'FBF',
'EAE',
'CDC'
], {
A: 'gtceu:hv_machine_hull',
B: 'tfg:machine_casing_aluminium_plated_steel',
C: '#gtceu:circuits/hv',
D: 'gtceu:stainless_steel_small_fluid_pipe',
E: 'gtceu:hv_electric_pump',
F: 'gtceu:fluid_filter'
}).addMaterialInfo().id('tfg:shaped/pisciculture_fishery');
// Pisciculture Core
event.recipes.gtceu.shaped('tfg:pisciculture_core', [
'CBC',
'DBD',
'CAC'
], {
A: 'gtceu:hv_rotor_holder',
B: 'gtceu:stainless_steel_rotor',
C: 'gtceu:inert_machine_casing',
D: ChemicalHelper.get(TagPrefix.ring, GTMaterials.PolyvinylChloride, 1)
}).addMaterialInfo().id('tfg:shaped/pisciculture_core');
//#endregion
//#region Recipes
global.FISH_INDEX.forEach(fish => {
// Bucket to Roe.
if (fish.parent !== null && fish.parent.includes('bucket')) {
generatePiscicultureRecipe(event,
fish.dimension, [
fish.parent,
fish.parent,
'6x #tfc:small_fishing_bait'
], [
`6x ${fish.item}`,
Item.of(`3x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
'2x minecraft:bucket'
],
`${fish.id.replace(/[/:\s]/g, "_")}/basic_food/bucket_to_roe`
);
generatePiscicultureRecipe(event,
fish.dimension, [
fish.parent,
fish.parent,
'2x #tfg:advanced_fish_food'
], [
`12x ${fish.item}`,
Item.of(`4x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
'2x minecraft:bucket'
],
`${fish.id.replace(/[/:\s]/g, "_")}/advanced_food/bucket_to_roe`
);
} else {
generatePiscicultureRecipe(event,
fish.dimension, [
fish.parent,
fish.parent,
'6x #tfc:small_fishing_bait'
], [
`6x ${fish.item}`,
Item.of(`3x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT()
],
`${fish.id.replace(/[/:\s]/g, "_")}/basic_food/parent_to_roe`
);
generatePiscicultureRecipe(event,
fish.dimension, [
fish.parent,
fish.parent,
'2x #tfg:advanced_fish_food'
], [
`12x ${fish.item}`,
Item.of(`4x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT()
],
`${fish.id.replace(/[/:\s]/g, "_")}/advanced_food/parent_to_roe`
);
};
// Roe to Roe.
generatePiscicultureRecipe(event,
fish.dimension, [
Item.of(`tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
Item.of(`tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
'6x #tfc:small_fishing_bait'
], [
`10x ${fish.item}`,
Item.of(`4x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT()
],
`${fish.id.replace(/[/:\s]/g, "_")}/basic_food/roe_to_roe`
);
generatePiscicultureRecipe(event,
fish.dimension, [
Item.of(`tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
Item.of(`tfg:fish_roe`, {"mob_type": fish.id}).strongNBT(),
'2x #tfg:advanced_fish_food'
], [
`15x ${fish.item}`,
Item.of(`5x tfg:fish_roe`, {"mob_type": fish.id}).strongNBT()
],
`${fish.id.replace(/[/:\s]/g, "_")}/advanced_food/roe_to_roe`
);
});
//#endregion
//#region Related Recipes
// Nitrate Rich Water Filtering
event.recipes.gtceu.electrolyzer('tfg:nitrate_rich_water_filtering')
.inputFluids(Fluid.of('tfg:nitrate_rich_water', 10000))
.outputFluids(
Fluid.of('minecraft:water', 8000),
Fluid.of('gtceu:ammonia', 1000)
)
.itemOutputs(ChemicalHelper.get(TagPrefix.dust, GTMaterials.Saltpeter, 1))
.duration(20 * 5)
.EUt(GTValues.VA[GTValues.HV]);
// Nitrate Rich Semiheavy Ammoniacal Water Filtering
event.recipes.gtceu.electrolyzer('tfg:nitrate_rich_semiheavy_ammoniacal_water_filtering')
.inputFluids(Fluid.of('tfg:nitrate_rich_semiheavy_ammoniacal_water', 10000))
.outputFluids(
Fluid.of('tfg:semiheavy_ammoniacal_water', 8000),
Fluid.of('gtceu:ammonia', 1000)
)
.itemOutputs(ChemicalHelper.get(TagPrefix.dust, GTMaterials.Saltpeter, 1))
.duration(20 * 5)
.EUt(GTValues.VA[GTValues.HV]);
//#endregion
};

View file

@ -0,0 +1,56 @@
"use strict";
/**
* @param {Internal.TagEventJS} event
*/
const registerTFGAquaponicsItemTags = (event) => {
event.add('tfg:treated_wood_greenhouse_casings', 'firmalife:treated_wood_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:treated_wood_greenhouse_wall');
event.add('tfg:copper_greenhouse_casings', 'firmalife:copper_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:copper_greenhouse_wall');
event.add('tfg:iron_greenhouse_casings', 'firmalife:iron_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:iron_greenhouse_wall');
event.add('tfg:stainless_steel_greenhouse_casings', 'firmalife:stainless_steel_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:stainless_steel_greenhouse_wall');
event.add('tfc:foods/usable_in_salad', 'tfg:fish_roe');
event.add('tfc:foods/usable_in_jam_sandwich', 'tfg:fish_roe');
event.add('tfc:foods/usable_in_sandwich', 'tfg:fish_roe');
event.add('tfc:foods/can_be_salted', 'tfg:fish_roe');
event.add('tfc:foods', 'tfg:fish_roe');
event.add('firmalife:foods/raw_fish', 'tfg:fish_roe');
event.add('minecraft:fishes', 'tfg:fish_roe');
event.add('tfg:advanced_fish_food', 'tfg:flora_pellets');
event.add('create:blaze_burner_fuel/regular', "tfg:flora_pellets");
};
/**
* @param {Internal.TagEventJS} event
*/
const registerTFGAquaponicsBlockTags = (event) => {
event.add('tfg:treated_wood_greenhouse_casings', 'firmalife:treated_wood_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:treated_wood_greenhouse_wall');
event.add('tfg:copper_greenhouse_casings', 'firmalife:copper_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:copper_greenhouse_wall');
event.add('tfg:iron_greenhouse_casings', 'firmalife:iron_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:iron_greenhouse_wall');
event.add('tfg:stainless_steel_greenhouse_casings', 'firmalife:stainless_steel_greenhouse_wall');
event.add('tfg:all_greenhouse_casings', 'firmalife:stainless_steel_greenhouse_wall');
};
/**
* @param {Internal.TagEventJS} event
*/
const registerTFGAquaponicsFluidTags = (event) => {
event.add('tfg:pisciculture_fishery_fluids', 'minecraft:water')
event.add('tfg:pisciculture_fishery_fluids', 'tfc:salt_water')
event.add('tfg:pisciculture_fishery_fluids', 'tfg:semiheavy_ammoniacal_water')
};

View file

@ -11,6 +11,7 @@ function registerTFCDataForTFG(event) {
registerTFGFLPlanters(event);
registerTFGFauna(event);
registerTFGEquipmentData(event);
registerTFGAquaponicsData(event);
}
//#region Heat Data

View file

@ -179,4 +179,4 @@ function registerTFGBiomassRecipes(event) {
.itemOutputs('gtceu:meat_dust', 'gtceu:tiny_bone_dust')
.duration(100)
.EUt(2)
}
}

View file

@ -303,8 +303,7 @@ function registerTFGFoodRecipes(event) {
itemOutputProvider: TFC.isp.of(`4x ${item.unsalted_cheese}`).copyOldestFood()
})
if (item.salted_wheel === null || item.salted_cheese === null)
return;
if (item.salted_wheel === null || item.salted_cheese === null) return;
global.processorRecipe(event, `${item.id}_salted_cheese_wheel`, 1000, 16, {
circuit: 2,
@ -381,8 +380,8 @@ function registerTFGFoodRecipes(event) {
for (const cshape of chocolateShape) {
global.processorRecipe(event, `${ctype}_${cshape}_melting`, 100, 16, {
circuit: 1,
itemInputs:[cshape == "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`],
fluidOutputs:[cshape == "" ? Fluid.of(`tfcchannelcasting:${ctype}`, 144) : Fluid.of(`tfcchannelcasting:${ctype}`, 100)],
itemInputs:[cshape === "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`],
fluidOutputs:[cshape === "" ? Fluid.of(`tfcchannelcasting:${ctype}`, 144) : Fluid.of(`tfcchannelcasting:${ctype}`, 100)]
})
}
}
@ -390,9 +389,9 @@ function registerTFGFoodRecipes(event) {
for (const ctype of chocolateType) {
for (const cshape of chocolateShape) {
global.processorRecipe(event, `${ctype}_${cshape}_casting`, 100, 16, {
fluidInputs: [cshape == "" ? Fluid.of(`tfcchannelcasting:${ctype}`, 144) : Fluid.of(`tfcchannelcasting:${ctype}`, 100)],
itemOutputs: [cshape == "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`],
itemOutputProvider: TFC.isp.of(cshape == "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`).resetFood(),
fluidInputs: [cshape === "" ? Fluid.of(`tfcchannelcasting:${ctype}`, 144) : Fluid.of(`tfcchannelcasting:${ctype}`, 100)],
itemOutputs: [cshape === "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`],
itemOutputProvider: TFC.isp.of(cshape === "" ? `firmalife:food/${ctype}` : `tfcchannelcasting:food/${ctype}${cshape}`).resetFood(),
notConsumable: [chocolatemolds[chocolateShape.indexOf(cshape)]]
})
}

View file

@ -99,7 +99,7 @@ function registerTFGMarsRecipes(event) {
'A A'
], {
A: 'tfg:wood/lumber/aeronos',
B: ChemicalHelper.get(TagPrefix.rod, GTMaterials.Wood, 1),
B: ChemicalHelper.get(TagPrefix.rod, GTMaterials.Wood, 1)
}).id('tfg:shaped/aeronos_ladder')
event.shaped('8x ad_astra:strophar_ladder', [
@ -108,29 +108,9 @@ function registerTFGMarsRecipes(event) {
'A A'
], {
A: 'tfg:wood/lumber/strophar',
B: ChemicalHelper.get(TagPrefix.rod, GTMaterials.Wood, 1),
B: ChemicalHelper.get(TagPrefix.rod, GTMaterials.Wood, 1)
}).id('tfg:shaped/strophar_ladder')
generateGreenHouseRecipe(event, '8x tfg:saplings/strophar', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x ad_astra:strophar_stem', 'tfg:green_house/strophar_mushroom', 'ad_astra:mars', 8,
'16x ad_astra:strophar_cap', GTValues.VA[GTValues.MV])
generateGreenHouseRecipe(event, '8x tfg:saplings/aeronos', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x ad_astra:aeronos_stem', 'tfg:green_house/aeronos_mushroom', 'ad_astra:mars', 8,
'16x ad_astra:aeronos_cap', GTValues.VA[GTValues.MV])
generateGreenHouseRecipe(event, '8x tfg:saplings/glacian', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x ad_astra:glacian_log', 'tfg:green_house/glacian_tree', 'ad_astra:mars', 8,
'8x species:alphacene_moss_block', GTValues.VA[GTValues.MV])
// Beneath woods
generateGreenHouseRecipe(event, '8x tfg:saplings/warped', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x beneath:wood/log/warped', 'tfg:green_house/warped_fungus', 'ad_astra:mars', 8,
'32x minecraft:warped_wart_block', GTValues.VA[GTValues.MV])
generateGreenHouseRecipe(event, '8x tfg:saplings/crimson', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x beneath:wood/log/crimson', 'tfg:green_house/crimson_fungus', 'ad_astra:mars', 8,
'32x minecraft:nether_wart_block', GTValues.VA[GTValues.MV])
// don't pass in the items like doors, trapdoors etc because beneath already has good recipes for those
woodBuilder(event, 'crimson', 'beneath:wood/lumber/crimson', '#tfc:crimson_logs', 'beneath:wood/log/crimson',
'beneath:wood/stripped_log/crimson', 'beneath:wood/planks/crimson', null,
@ -164,12 +144,6 @@ function registerTFGMarsRecipes(event) {
.processingTime(50 * global.VINTAGE_IMPROVEMENTS_DURATION_MULTIPLIER)
.id(`tfg:vi/lathe/stripping_warped_wood`)
// Alphacene
generateGreenHouseRecipe(event, '8x tfg:saplings/alphacene', 'tfg:semiheavy_ammoniacal_water', 16000,
'64x species:alphacene_mushroom_block', 'tfg:green_house/alphacene_mushroom', 'ad_astra:mars', 8,
'8x minecraft:mushroom_stem', GTValues.VA[GTValues.MV])
//Large Nest
event.shaped('tfg:large_nest_box',
[
@ -247,34 +221,6 @@ function registerTFGMarsRecipes(event) {
B: '#tfc:lumber'
}).id('tfg:shaped/glacian_bed')
// Plants
Ingredient.of('#tfg:mars_plants').stacks.forEach(element => {
const itemId = element.id;
const recipeId = `greenhouse_${itemId.replace(':', '_')}`;
generateGreenHouseRecipe(event, itemId, 'tfg:semiheavy_ammoniacal_water', 8000, `8x ${itemId}`,
recipeId, 'ad_astra:mars', 8, itemId, GTValues.VA[GTValues.LV]);
});
generateGreenHouseRecipe(event, '8x betterend:amber_root_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:amber_root_product', 'amber_root', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '8x betterend:blossom_berry_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:blossom_berry_product', 'blossom_berry', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '8x betterend:bolux_mushroom_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:bolux_mushroom_product', 'bolux_mushroom', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '8x betterend:cave_pumpkin_plant_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:cave_pumpkin', 'cave_pumpkin', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '8x betterend:chorus_mushroom_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:chorus_mushroom_product', 'chorus_mushroom', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
generateGreenHouseRecipe(event, '8x betterend:shadow_berry_seeds', 'tfg:semiheavy_ammoniacal_water', 8000,
'24x betterend:shadow_berry_product', 'shadow_berry', 'ad_astra:mars', 8, null, GTValues.VA[GTValues.LV])
event.recipes.firmalife.oven('betterend:cave_pumpkin_pie_raw', 400, 60 * 20, 'betterend:cave_pumpkin_pie')
// Mars primitive stuff

View file

@ -2,40 +2,13 @@
function registerTFGMoonPlantRecipes(event) {
// Plants - Can't use the default builder here because fertiliser is much harder to get on the moon,
// and we're using helium-3 as the fertiliser
// Chorus
event.recipes.gtceu.greenhouse('tfg:chorus')
.notConsumable('8x tfg:lunar_chorus_flower')
.itemOutputs('64x minecraft:chorus_fruit')
.chancedOutput('8x tfg:lunar_chorus_flower', 750, 0)
.chancedOutput('8x tfg:lunar_chorus_flower', 500, 0)
.chancedOutput('8x tfg:lunar_chorus_flower', 750, 0)
.duration(36000) // 30 mins
.circuit(1)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
event.recipes.gtceu.greenhouse('tfg:chorus_helium')
.notConsumable('8x tfg:lunar_chorus_flower')
.inputFluids(Fluid.of('gtceu:helium_3', 2000))
.itemOutputs('64x minecraft:chorus_fruit')
.chancedOutput('8x tfg:lunar_chorus_flower', 4000, 0)
.chancedOutput('8x tfg:lunar_chorus_flower', 3000, 0)
.chancedOutput('8x tfg:lunar_chorus_flower', 4000, 0)
.duration(12000) // 10 mins
.circuit(2)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
// Replace the built-in greg one to add a circuit
event.recipes.gtceu.fermenter('fermented_biomass')
.inputFluids(Fluid.of('gtceu:biomass', 100))
.outputFluids(Fluid.of('gtceu:fermented_biomass', 100))
.circuit(1)
.duration(150)
.EUt(2)
.EUt(2);
event.recipes.gtceu.fermenter('tfg:chorus')
.itemInputs('minecraft:chorus_fruit')
@ -45,7 +18,7 @@ function registerTFGMoonPlantRecipes(event) {
.circuit(2)
.duration(5 * 20)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
.dimension('ad_astra:moon');
event.recipes.gtceu.fermenter('tfg:chorus_flower')
.itemInputs('tfg:lunar_chorus_flower')
@ -55,64 +28,12 @@ function registerTFGMoonPlantRecipes(event) {
.circuit(2)
.duration(5 * 20)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
.dimension('ad_astra:moon');
// Lightblooms
event.recipes.gtceu.greenhouse('tfg:lightbloom')
.notConsumable('8x minecraft:twisting_vines')
.itemOutputs('16x minecraft:twisting_vines')
.chancedOutput('minecraft:pearlescent_froglight', 2500, 0)
.chancedOutput('minecraft:verdant_froglight', 2500, 0)
.chancedOutput('minecraft:ochre_froglight', 2500, 0)
.duration(36000) // 30 mins
.circuit(1)
.EUt(GTValues.VA[GTValues.LV])
.dimension('ad_astra:moon')
event.recipes.gtceu.greenhouse('tfg:lightbloom_helium')
.notConsumable('8x minecraft:twisting_vines')
.inputFluids(Fluid.of('gtceu:helium_3', 2000))
.itemOutputs('16x minecraft:twisting_vines')
.chancedOutput('minecraft:pearlescent_froglight', 3500, 0)
.chancedOutput('minecraft:verdant_froglight', 3500, 0)
.chancedOutput('minecraft:ochre_froglight', 3500, 0)
.duration(12000) // 30 mins
.circuit(2)
.EUt(GTValues.VA[GTValues.LV])
.dimension('ad_astra:moon')
event.recipes.gtceu.brewery('biomass_from_twisting_vines')
.itemInputs('minecraft:twisting_vines')
.inputFluids("#tfg:clean_water 20")
.outputFluids(Fluid.of('gtceu:biomass', 20))
.duration(50)
.EUt(3)
Ingredient.of('#tfg:moon_plants').stacks.forEach(element => {
const itemId = element.id;
const recipeId = `betterend:greenhouse_${itemId.replace(':', '_')}`;
event.recipes.gtceu.greenhouse(recipeId)
.notConsumable(element.id)
.itemOutputs(`8x ${element.id}`)
.chancedOutput(element.id, 750, 0)
.chancedOutput(element.id, 500, 0)
.chancedOutput(element.id, 750, 0)
.duration(36000) // 30 mins
.circuit(1)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
event.recipes.gtceu.greenhouse(`${recipeId}_helium`)
.notConsumable(element.id)
.inputFluids(Fluid.of('gtceu:helium_3', 500))
.itemOutputs(`8x ${element.id}`)
.chancedOutput(element.id, 4000, 0)
.chancedOutput(element.id, 3000, 0)
.chancedOutput(element.id, 4000, 0)
.duration(12000) // 30 mins
.circuit(2)
.EUt(GTValues.VA[GTValues.MV])
.dimension('ad_astra:moon')
});
}
event.recipes.gtceu.brewery('biomass_from_twisting_vines')
.itemInputs('minecraft:twisting_vines')
.inputFluids("#tfg:clean_water 20")
.outputFluids(Fluid.of('gtceu:biomass', 20))
.duration(50)
.EUt(3);
};

View file

@ -60,10 +60,15 @@ function registerTFGBoilerRecipes(event) {
.duration(75)
.dimension('minecraft:overworld')
event.recipes.gtceu.steam_boiler('tfg:flora_pellets')
.itemInputs('tfg:flora_pellets')
.duration(1200)
.dimension('minecraft:overworld')
// Small nerf to charcoal
event.forEachRecipe({ id: /gtceu:(steam_boiler|large_boiler)\/.*charcoal.*/ }, recipe => {
var newDuration = recipe.get("duration")
let newDuration = recipe.get("duration")
recipe.set("duration", newDuration/4*3)
})

View file

@ -14,6 +14,9 @@ const registerTFGRecipes = (event) => {
registerTFGRefrigeratorRecipes(event)
registerTFGMealBagRecipes(event)
registerTFGBiomassRecipes(event)
// Greenhouse needs to register before pisciculture.
registerTFGGreenhouseRecipes(event)
registerTFGPiscicultureRecipes(event)
// TFC stone types
registerTFCStoneRecipes(event)

View file

@ -169,4 +169,12 @@ function registerTFGMiscellaneousRecipes(event) {
TFGHelpers.registerMaterialInfo('tfg:rnr_plow', { 'cobalt_brass': 9, 'invar': 4, 'steel': 2, 'wrought_iron': 3, 'treated_wood': 2 });
//#endregion
// Rotten Voiding Cover
event.recipes.gtceu.assembler('tfg:rotten_voiding_cover')
.itemInputs('gtceu:item_voiding_cover', '8x tfc:rotten_compost')
.itemOutputs('tfg:rotten_voiding_cover')
.duration(5*20)
.EUt(GTValues.VA[GTValues.LV])
.addMaterialInfo(true);
}

View file

@ -17,6 +17,7 @@ const registerTFGItemTags = (event) => {
registerTFGMoonItemTags(event)
registerTFGMarsItemTags(event)
registerTFGVenusItemTags(event)
registerTFGAquaponicsItemTags(event)
// TEMPORARY, REMOVE WHEN GURMAN FIXES THIS
event.remove('tfc:foods', 'tfc_gurman:havai_pizza')
@ -115,6 +116,7 @@ const registerTFGBlockTags = (event) => {
registerTFGMoonBlockTags(event)
registerTFGMarsBlockTags(event)
registerTFGVenusBlockTags(event)
registerTFGAquaponicsBlockTags(event)
event.add('minecraft:mineable/pickaxe', 'tfg:superconductor_coil_large')
event.add('minecraft:mineable/pickaxe', 'tfg:superconductor_coil_small')
@ -140,6 +142,7 @@ const registerTFGBlockTags = (event) => {
//#region Fluids
const registerTFGFluidTags = (event) => {
registerTFGAquaponicsFluidTags(event)
registerTFGPrimitiveFluidTags(event)
event.add('tfg:clean_water', 'minecraft:water')

View file

@ -462,6 +462,22 @@ function registerTFGBiochemRecipes(event) {
organics.forEach(organic =>
deccellularizationRecipe(event, organic.type, organic.id, organic.amount)
);
// Chlorplast "Centrifuging"
event.recipes.gtceu.bioreactor('tfg:chloroplasts')
.notConsumableFluid(
Fluid.of('gtceu:glycerol', 1000)
)
.inputFluids(
Fluid.of('gtceu:biomass', 8000)
)
.outputFluids(
Fluid.of('tfg:chloroplasts', 100),
Fluid.of('minecraft:water', 6000),
Fluid.of('gtceu:seed_oil', 1900)
)
.duration(20*20)
.EUt(GTValues.VA[GTValues.EV]);
//#endregion
//#region Gram Stain