Consolidating Development: 0.9.x (#846)

Signed-off-by: Pyritie <pyritie@gmail.com>
Signed-off-by: TomPlop <tomdidome@gmail.com>
Co-authored-by: Pyritie <Pyritie@gmail.com>
Co-authored-by: Redeix <brayden.j.m.ford@gmail.com>
Co-authored-by: TomPlop <tomdidome@gmail.com>
Co-authored-by: aidie8 <aidenvanzuilen@gmail.com>
Co-authored-by: Xikaro <os.valerievich@ya.ru>
Co-authored-by: Xikaro <55663835+Xikaro@users.noreply.github.com>
Co-authored-by: Zleub <debray.arnaud@gmail.com>
This commit is contained in:
Nebby 2025-04-14 14:00:08 -04:00 committed by GitHub
parent 528672e95b
commit d4c80a4b61
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2192 changed files with 104647 additions and 53190 deletions

View file

@ -5,69 +5,7 @@
* у которых должны быть удалены тэги и они должны быть скрыты в REI.
*/
global.TFC_DISABLED_ITEMS = [
// Blocks
'tfc:metal/block/bismuth',
'tfc:metal/block/bismuth_bronze',
'tfc:metal/block/black_bronze',
'tfc:metal/block/bronze',
'tfc:metal/block/brass',
'tfc:metal/block/copper',
'tfc:metal/block/gold',
'tfc:metal/block/nickel',
'tfc:metal/block/rose_gold',
'tfc:metal/block/silver',
'tfc:metal/block/tin',
'tfc:metal/block/zinc',
'tfc:metal/block/sterling_silver',
'tfc:metal/block/wrought_iron',
'tfc:metal/block/cast_iron',
'tfc:metal/block/steel',
'tfc:metal/block/black_steel',
'tfc:metal/block/blue_steel',
'tfc:metal/block/red_steel',
// Stairs
'tfc:metal/block/bismuth_stairs',
'tfc:metal/block/bismuth_bronze_stairs',
'tfc:metal/block/black_bronze_stairs',
'tfc:metal/block/bronze_stairs',
'tfc:metal/block/brass_stairs',
'tfc:metal/block/copper_stairs',
'tfc:metal/block/gold_stairs',
'tfc:metal/block/nickel_stairs',
'tfc:metal/block/rose_gold_stairs',
'tfc:metal/block/silver_stairs',
'tfc:metal/block/tin_stairs',
'tfc:metal/block/zinc_stairs',
'tfc:metal/block/sterling_silver_stairs',
'tfc:metal/block/wrought_iron_stairs',
'tfc:metal/block/cast_iron_stairs',
'tfc:metal/block/steel_stairs',
'tfc:metal/block/black_steel_stairs',
'tfc:metal/block/blue_steel_stairs',
'tfc:metal/block/red_steel_stairs',
// Slabs
'tfc:metal/block/bismuth_slab',
'tfc:metal/block/bismuth_bronze_slab',
'tfc:metal/block/black_bronze_slab',
'tfc:metal/block/bronze_slab',
'tfc:metal/block/brass_slab',
'tfc:metal/block/copper_slab',
'tfc:metal/block/gold_slab',
'tfc:metal/block/nickel_slab',
'tfc:metal/block/rose_gold_slab',
'tfc:metal/block/silver_slab',
'tfc:metal/block/tin_slab',
'tfc:metal/block/zinc_slab',
'tfc:metal/block/sterling_silver_slab',
'tfc:metal/block/wrought_iron_slab',
'tfc:metal/block/cast_iron_slab',
'tfc:metal/block/steel_slab',
'tfc:metal/block/black_steel_slab',
'tfc:metal/block/blue_steel_slab',
'tfc:metal/block/red_steel_slab',
// Ingots
"tfc:metal/ingot/bismuth",
"tfc:metal/ingot/bismuth_bronze",
@ -77,9 +15,6 @@ global.TFC_DISABLED_ITEMS = [
"tfc:metal/ingot/sterling_silver",
"tfc:metal/ingot/wrought_iron",
"tfc:metal/ingot/steel",
"tfc:metal/ingot/black_steel",
"tfc:metal/ingot/red_steel",
"tfc:metal/ingot/blue_steel",
"tfc:metal/ingot/brass",
"tfc:metal/ingot/nickel",
"tfc:metal/ingot/silver",
@ -98,15 +33,11 @@ global.TFC_DISABLED_ITEMS = [
"tfc:metal/double_ingot/sterling_silver",
"tfc:metal/double_ingot/wrought_iron",
"tfc:metal/double_ingot/steel",
"tfc:metal/double_ingot/black_steel",
"tfc:metal/double_ingot/red_steel",
"tfc:metal/double_ingot/blue_steel",
"tfc:metal/double_ingot/brass",
"tfc:metal/double_ingot/nickel",
"tfc:metal/double_ingot/silver",
"tfc:metal/double_ingot/tin",
"tfc:metal/double_ingot/zinc",
"tfc:metal/double_ingot/cast_iron",
"tfc:metal/double_ingot/copper",
"tfc:metal/double_ingot/gold",
@ -357,44 +288,6 @@ global.TFC_DISABLED_ITEMS = [
'tfc:metal/scythe/blue_steel',
'tfc:metal/scythe_blade/blue_steel',
// Ores
'tfc:ore/poor_native_copper',
'tfc:ore/normal_native_copper',
'tfc:ore/rich_native_copper',
'tfc:ore/poor_native_gold',
'tfc:ore/normal_native_gold',
'tfc:ore/rich_native_gold',
'tfc:ore/poor_hematite',
'tfc:ore/normal_hematite',
'tfc:ore/rich_hematite',
'tfc:ore/rich_tetrahedrite',
'tfc:ore/normal_tetrahedrite',
'tfc:ore/poor_tetrahedrite',
'tfc:ore/rich_sphalerite',
'tfc:ore/normal_sphalerite',
'tfc:ore/poor_sphalerite',
'tfc:ore/rich_limonite',
'tfc:ore/normal_limonite',
'tfc:ore/poor_limonite',
'tfc:ore/rich_magnetite',
'tfc:ore/normal_magnetite',
'tfc:ore/poor_magnetite',
'tfc:ore/rich_malachite',
'tfc:ore/normal_malachite',
'tfc:ore/poor_malachite',
'tfc:ore/rich_garnierite',
'tfc:ore/normal_garnierite',
'tfc:ore/poor_garnierite',
'tfc:ore/rich_bismuthinite',
'tfc:ore/normal_bismuthinite',
'tfc:ore/poor_bismuthinite',
'tfc:ore/rich_cassiterite',
'tfc:ore/normal_cassiterite',
'tfc:ore/poor_cassiterite',
'tfc:ore/rich_native_silver',
'tfc:ore/normal_native_silver',
'tfc:ore/poor_native_silver',
// Gems
'tfc:gem/amethyst',
'tfc:gem/diamond',
@ -421,7 +314,6 @@ global.TFC_DISABLED_ITEMS = [
'tfc:ore/cryolite',
'tfc:ore/saltpeter',
'tfc:ore/borax',
'tfc:ore/sylvite',
'tfc:ore/bituminous_coal',
'tfc:ore/lignite',
'tfc:ore/halite',
@ -582,6 +474,8 @@ global.TFC_DISABLED_ITEMS = [
// Windmill Blades
"tfc:windmill_blade",
"tfc:rustic_windmill_blade",
"tfc:lattice_windmill_blade",
"tfc:orange_windmill_blade",
"tfc:magenta_windmill_blade",
"tfc:light_blue_windmill_blade",
@ -656,6 +550,9 @@ global.TFC_DISABLED_ITEMS = [
'tfc:crankshaft',
'tfc:hand_wheel_base',
'tfc:hand_wheel',
'tfc:blank_disc',
'tfc:sandpaper',
'tfc:brass_mechanisms'
];
/**
@ -999,9 +896,8 @@ global.TFC_QUERN_POWDER_RECIPE_COMPONENTS = [
{ input: '#forge:dusts/borax', output: '4x tfc:powder/flux', name: 'flux_powder' },
{ input: '#forge:dusts/soda_ash', output: '4x tfc:powder/soda_ash', name: 'soda_ash' },
{ input: 'gtceu:charcoal_dust', output: '2x tfc:powder/charcoal', name: 'charcoal' },
{ input: 'gtceu:raw_graphite', output: 'gtceu:graphite_dust', name: 'raw_graphite_to_dust' },
{ input: 'gtceu:poor_raw_graphite', output: '5x gtceu:tiny_graphite_dust', name: 'poor_raw_graphite_to_dust' },
{ input: 'gtceu:rich_raw_graphite', output: '2x gtceu:graphite_dust', name: 'rich_graphite_to_dust' },
{ input: 'tfc:ore/sylvite', output: '4x tfc:powder/sylvite', name: 'sylvite' },
{ input: 'firmalife:ore/small_chromite', output: 'gtceu:small_chromite_dust', name: 'chromite' }
];
global.TFC_QUERN_GRAIN_RECIPE_COMPONENTS = [
@ -1041,41 +937,41 @@ global.TFC_FURNACE_BREAD_RECIPE_COMPONENTS = [
];
global.TFC_GREENHOUSE_FRUIT_RECIPE_COMPONENTS = [
{ input: 'tfc:plant/cherry_sapling', fluid_amount: 8000, output: '3x tfc:food/cherry', name: 'cherry' },
{ input: 'tfc:plant/green_apple_sapling', fluid_amount: 8000, output: '3x tfc:food/green_apple', name: 'green_apple' },
{ input: 'tfc:plant/lemon_sapling', fluid_amount: 8000, output: '3x tfc:food/lemon', name: 'lemon' },
{ input: 'tfc:plant/olive_sapling', fluid_amount: 8000, output: '3x tfc:food/olive', name: 'olive' },
{ input: 'tfc:plant/orange_sapling', fluid_amount: 8000, output: '3x tfc:food/orange', name: 'orange' },
{ input: 'tfc:plant/peach_sapling', fluid_amount: 8000, output: '3x tfc:food/peach', name: 'peach' },
{ input: 'tfc:plant/plum_sapling', fluid_amount: 8000, output: '3x tfc:food/plum', name: 'plum' },
{ input: 'tfc:plant/red_apple_sapling', fluid_amount: 8000, output: '3x tfc:food/red_apple', name: 'red_apple' },
{ input: 'tfc:plant/banana_sapling', fluid_amount:8000, output: '3x tfc:food/banana', name: 'banana' },
{ input: 'tfc:plant/cherry_sapling', fluid_amount: 8000, output: '32x tfc:food/cherry', name: 'cherry' },
{ input: 'tfc:plant/green_apple_sapling', fluid_amount: 8000, output: '32x tfc:food/green_apple', name: 'green_apple' },
{ input: 'tfc:plant/lemon_sapling', fluid_amount: 8000, output: '32x tfc:food/lemon', name: 'lemon' },
{ input: 'tfc:plant/olive_sapling', fluid_amount: 8000, output: '32x tfc:food/olive', name: 'olive' },
{ input: 'tfc:plant/orange_sapling', fluid_amount: 8000, output: '32x tfc:food/orange', name: 'orange' },
{ input: 'tfc:plant/peach_sapling', fluid_amount: 8000, output: '32x tfc:food/peach', name: 'peach' },
{ input: 'tfc:plant/plum_sapling', fluid_amount: 8000, output: '32x tfc:food/plum', name: 'plum' },
{ input: 'tfc:plant/red_apple_sapling', fluid_amount: 8000, output: '32x tfc:food/red_apple', name: 'red_apple' },
{ input: 'tfc:plant/banana_sapling', fluid_amount:8000, output: '32x tfc:food/banana', name: 'banana' },
];
global.TFC_GREENHOUSE_VEGETABLE_RECIPE_COMPONENTS = [
{ input: 'tfc:seeds/barley', fluid_amount: 4000, output: '3x tfc:food/barley', name: 'barley' },
{ input: 'tfc:seeds/oat', fluid_amount: 4000, output: '3x tfc:food/oat', name: 'oat' },
{ input: 'tfc:seeds/rye', fluid_amount: 4000, output: '3x tfc:food/rye', name: 'rye' },
{ input: 'tfc:seeds/maize', fluid_amount: 4000, output: '3x tfc:food/maize', name: 'maize' },
{ input: 'tfc:seeds/wheat', fluid_amount: 4000, output: '3x tfc:food/wheat', name: 'wheat' },
{ input: 'tfc:seeds/rice', fluid_amount: 4000, output: '3x tfc:food/rice', name: 'rice' },
{ input: 'tfc:seeds/beet', fluid_amount: 4000, output: '3x tfc:food/beet', name: 'beet' },
{ input: 'tfc:seeds/cabbage', fluid_amount: 4000, output: '3x tfc:food/cabbage', name: 'cabbage' },
{ input: 'tfc:seeds/carrot', fluid_amount: 4000, output: '3x tfc:food/carrot', name: 'carrot' },
{ input: 'tfc:seeds/green_bean', fluid_amount: 4000, output: '3x tfc:food/green_bean', name: 'green_bean' },
{ input: 'tfc:seeds/garlic', fluid_amount: 4000, output: '3x tfc:food/garlic', name: 'garlic' },
{ input: 'tfc:seeds/potato', fluid_amount: 4000, output: '3x tfc:food/potato', name: 'potato' },
{ input: 'tfc:seeds/onion', fluid_amount: 4000, output: '3x tfc:food/onion', name: 'onion' },
{ input: 'tfc:seeds/soybean', fluid_amount: 4000, output: '3x tfc:food/soybean', name: 'soybean' },
{ input: 'tfc:seeds/squash', fluid_amount: 4000, output: '3x tfc:food/squash', name: 'squash' },
{ input: 'tfc:seeds/sugarcane', fluid_amount: 4000, output: '3x tfc:food/sugarcane', name: 'sugarcane' },
{ input: 'tfc:seeds/tomato', fluid_amount: 4000, output: '3x tfc:food/tomato', name: 'tomato' },
{ input: 'tfc:seeds/jute', fluid_amount: 4000, output: '3x tfc:jute', name: 'jute' },
{ input: 'tfc:seeds/papyrus', fluid_amount: 4000, output: '3x tfc:papyrus', name: 'papyrus' },
{ input: 'tfc:seeds/pumpkin', fluid_amount: 4000, output: '3x tfc:pumpkin', name: 'pumpkin' },
{ input: 'tfc:seeds/melon', fluid_amount: 4000, output: '3x tfc:melon', name: 'melon' },
{ input: 'tfc:seeds/red_bell_pepper', fluid_amount: 4000, output: '3x tfc:food/red_bell_pepper', name: 'red_bell_pepper' },
{ input: 'tfc:seeds/yellow_bell_pepper', fluid_amount: 4000, output: '3x tfc:food/yellow_bell_pepper', name: 'yellow_bell_pepper' },
{ input: '8x tfc:seeds/barley', fluid_amount: 4000, output: '24x tfc:food/barley', name: 'barley' },
{ input: '8x tfc:seeds/oat', fluid_amount: 4000, output: '24x tfc:food/oat', name: 'oat' },
{ input: '8x tfc:seeds/rye', fluid_amount: 4000, output: '24x tfc:food/rye', name: 'rye' },
{ input: '8x tfc:seeds/maize', fluid_amount: 4000, output: '24x tfc:food/maize', name: 'maize' },
{ input: '8x tfc:seeds/wheat', fluid_amount: 4000, output: '24x tfc:food/wheat', name: 'wheat' },
{ input: '8x tfc:seeds/rice', fluid_amount: 4000, output: '24x tfc:food/rice', name: 'rice' },
{ input: '8x tfc:seeds/beet', fluid_amount: 4000, output: '24x tfc:food/beet', name: 'beet' },
{ input: '8x tfc:seeds/cabbage', fluid_amount: 4000, output: '24x tfc:food/cabbage', name: 'cabbage' },
{ input: '8x tfc:seeds/carrot', fluid_amount: 4000, output: '24x tfc:food/carrot', name: 'carrot' },
{ input: '8x tfc:seeds/green_bean', fluid_amount: 4000, output: '24x tfc:food/green_bean', name: 'green_bean' },
{ input: '8x tfc:seeds/garlic', fluid_amount: 4000, output: '24x tfc:food/garlic', name: 'garlic' },
{ input: '8x tfc:seeds/potato', fluid_amount: 4000, output: '24x tfc:food/potato', name: 'potato' },
{ input: '8x tfc:seeds/onion', fluid_amount: 4000, output: '24x tfc:food/onion', name: 'onion' },
{ input: '8x tfc:seeds/soybean', fluid_amount: 4000, output: '24x tfc:food/soybean', name: 'soybean' },
{ input: '8x tfc:seeds/squash', fluid_amount: 4000, output: '24x tfc:food/squash', name: 'squash' },
{ input: '8x tfc:seeds/sugarcane', fluid_amount: 4000, output: '24x tfc:food/sugarcane', name: 'sugarcane' },
{ input: '8x tfc:seeds/tomato', fluid_amount: 4000, output: '24x tfc:food/tomato', name: 'tomato' },
{ input: '8x tfc:seeds/jute', fluid_amount: 4000, output: '24x tfc:jute', name: 'jute' },
{ input: '8x tfc:seeds/papyrus', fluid_amount: 4000, output: '24x tfc:papyrus', name: 'papyrus' },
{ input: '8x tfc:seeds/pumpkin', fluid_amount: 4000, output: '24x tfc:pumpkin', name: 'pumpkin' },
{ input: '8x tfc:seeds/melon', fluid_amount: 4000, output: '24x tfc:melon', name: 'melon' },
{ input: '8x tfc:seeds/red_bell_pepper', fluid_amount: 4000, output: '24x tfc:food/red_bell_pepper', name: 'red_bell_pepper' },
{ input: '8x tfc:seeds/yellow_bell_pepper', fluid_amount: 4000, output: '24x tfc:food/yellow_bell_pepper', name: 'yellow_bell_pepper' },
];
global.TFC_GREENHOUSE_BERRY_RECIPE_COMPONENTS = [

View file

@ -0,0 +1,37 @@
// priority: 0
function registerTFCIconSets(event) {
event.create('tfc_borax').parent('rough')
event.create('tfc_gypsum').parent('rough')
event.create('tfc_graphite').parent('rough')
event.create('tfc_saltpeter').parent('fine')
event.create('tfc_sulfur').parent('fine')
event.create('tfc_amethyst').parent('ruby')
event.create('tfc_redstone').parent('fine')
event.create('tfc_diamond').parent('diamond')
event.create('tfc_emerald').parent('emerald')
event.create('tfc_lapis').parent('lapis')
event.create('tfc_opal').parent('opal')
event.create('tfc_pyrite').parent('bright')
event.create('tfc_ruby').parent('ruby')
event.create('tfc_sapphire').parent('gem_horizontal')
event.create('tfc_topaz').parent('gem_vertical')
event.create('tfc_bismuth').parent('bright')
event.create('tfc_cassiterite').parent('bright')
event.create('tfc_garnierite').parent('bright')
event.create('tfc_hematite').parent('metallic')
event.create('tfc_limonite').parent('metallic')
event.create('tfc_magnetite').parent('dull')
event.create('tfc_malachite').parent('shiny')
event.create('tfc_copper').parent('bright')
event.create('tfc_gold').parent('metallic')
event.create('tfc_silver').parent('shiny')
event.create('tfc_sphalerite').parent('dull')
event.create('tfc_tetrahedrite').parent('dull')
event.create('tfc_chromite').parent('dull')
event.create('nether_quartz').parent('quartz')
}

View file

@ -0,0 +1,127 @@
// priority: 0
const registerTFCMaterials = (event) => {
const registerStoneMaterial = (rockType, color) =>
event.create(`tfg:${rockType}`)
.dust()
.color(color)
.iconSet(GTMaterialIconSet.ROUGH)
.flags(
GTMaterialFlags.MORTAR_GRINDABLE,
GTMaterialFlags.NO_SMASHING,
GTMaterialFlags.NO_SMELTING
)
/* TFC Stone Types Materials */
registerStoneMaterial('gabbro', 0x7F8081)
registerStoneMaterial('shale', 0x686567)
registerStoneMaterial('claystone', 0xAF9377)
registerStoneMaterial('limestone', 0xA09885)
registerStoneMaterial('conglomerate', 0xA3977F)
registerStoneMaterial('dolomite', 0x515155)
registerStoneMaterial('chert', 0x7A6756)
registerStoneMaterial('chalk', 0xA4A39F)
registerStoneMaterial('rhyolite', 0x726D69)
registerStoneMaterial('dacite', 0x979797)
registerStoneMaterial('slate', 0x989287)
registerStoneMaterial('phyllite', 0x706B61)
registerStoneMaterial('schist', 0x6E735C)
registerStoneMaterial('gneiss', 0x6A6D60)
registerStoneMaterial('dripstone', 0x927965)
// Specialized icon sets for TFC's own
GTMaterials.Coal.setMaterialIconSet(GTMaterialIconSet.LIGNITE)
GTMaterials.Borax.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_borax'))
GTMaterials.Gypsum.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gypsum'))
GTMaterials.Graphite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_graphite'))
GTMaterials.Saltpeter.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_saltpeter'))
GTMaterials.Sulfur.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sulfur'))
GTMaterials.Amethyst.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_amethyst'))
GTMaterials.Redstone.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_redstone'))
GTMaterials.Diamond.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_diamond'))
GTMaterials.Emerald.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_emerald'))
GTMaterials.Lapis.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_lapis'))
GTMaterials.Opal.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_opal'))
GTMaterials.Pyrite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_pyrite'))
GTMaterials.Ruby.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_ruby'))
GTMaterials.Sapphire.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sapphire'))
GTMaterials.GreenSapphire.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_topaz'))
GTMaterials.Topaz.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_topaz'))
GTMaterials.BlueTopaz.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sapphire'))
GTMaterials.Bismuth.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_bismuth'))
GTMaterials.Cassiterite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_cassiterite'))
GTMaterials.Tin.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_cassiterite'))
GTMaterials.Garnierite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_garnierite'))
GTMaterials.Nickel.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_garnierite'))
GTMaterials.Hematite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_hematite'))
GTMaterials.YellowLimonite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_limonite'))
GTMaterials.Magnetite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_magnetite'))
GTMaterials.Malachite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_malachite'))
GTMaterials.Copper.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_copper'))
GTMaterials.Chalcocite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_copper'))
GTMaterials.Gold.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gold'))
GTMaterials.Silver.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_silver'))
GTMaterials.Sphalerite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sphalerite'))
GTMaterials.Tetrahedrite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_tetrahedrite'))
GTMaterials.Chalcopyrite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_tetrahedrite'))
GTMaterials.Chromite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_chromite'))
GTMaterials.NetherQuartz.setMaterialIconSet(GTMaterialIconSet.getByName('nether_quartz'))
GTMaterials.RedAlloy.setMaterialIconSet(GTMaterialIconSet.SHINY)
GTMaterials.TinAlloy.setMaterialIconSet(GTMaterialIconSet.SHINY)
GTMaterials.BismuthBronze.setMaterialIconSet(GTMaterialIconSet.BRIGHT)
GTMaterials.Nickel.setMaterialIconSet(GTMaterialIconSet.BRIGHT)
GTMaterials.BlackBronze.setMaterialIconSet(GTMaterialIconSet.SHINY)
GTMaterials.Aluminium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_silver'))
GTMaterials.Asbestos.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gold'))
GTMaterials.Almandine.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_redstone'))
GTMaterials.Beryllium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_copper'))
GTMaterials.Cobalt.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sphalerite'))
GTMaterials.Cobaltite.setMaterialIconSet(GTMaterialIconSet.LAPIS)
GTMaterials.Lead.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_magnetite'))
GTMaterials.Lazurite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_ruby'))
GTMaterials.Asbestos.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_lapis'))
GTMaterials.Lithium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_hematite'))
GTMaterials.Galena.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_copper'))
GTMaterials.Grossular.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sapphire'))
GTMaterials.Neodymium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_magnetite'))
GTMaterials.Palladium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_pyrite'))
GTMaterials.Platinum.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gold'))
GTMaterials.Thorium.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_hematite'))
GTMaterials.Naquadah.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_malachite'))
GTMaterials.Goethite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_silver'))
GTMaterials.Calcite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_borax'))
GTMaterials.Cooperite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gold'))
GTMaterials.Sodalite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_opal'))
GTMaterials.Molybdenum.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_chromite'))
GTMaterials.Powellite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sphalerite'))
GTMaterials.Pyrolusite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_tetrahedrite'))
GTMaterials.Apatite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_opal'))
GTMaterials.Pyrope.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_opal'))
GTMaterials.Scheelite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_saltpeter'))
GTMaterials.Tantalite.setMaterialIconSet(GTMaterialIconSet.LIGNITE)
GTMaterials.Stibnite.setMaterialIconSet(GTMaterialIconSet.LAPIS)
GTMaterials.Tungstate.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_borax'))
GTMaterials.Uraninite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_limonite'))
GTMaterials.Pitchblende.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_magnetite'))
GTMaterials.VanadiumMagnetite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_chromite'))
GTMaterials.Wulfenite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_borax'))
GTMaterials.Realgar.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_redstone'))
GTMaterials.Spodumene.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_gypsum'))
GTMaterials.Mica.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_sulfur'))
GTMaterials.Barite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_graphite'))
GTMaterials.Alunite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_saltpeter'))
GTMaterials.Pyrochlore.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_hematite'))
GTMaterials.Olivine.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_topaz'))
GTMaterials.GarnetYellow.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_redstone'))
GTMaterials.Trona.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_pyrite'))
GTMaterials.Zeolite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_copper'))
GTMaterials.Electrotine.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_garnierite'))
GTMaterials.Bauxite.setMaterialIconSet(GTMaterialIconSet.getByName('tfc_borax'))
}

View file

@ -0,0 +1,163 @@
const $ICalendar = Java.loadClass('net.dries007.tfc.util.calendar.ICalendar')
const TICKS_IN_HOUR = $ICalendar.TICKS_IN_HOUR;
const TICKS_IN_DAY = $ICalendar.TICKS_IN_DAY;
const SIX_TIMES_TICKS_IN_HOUR = TICKS_IN_HOUR * 6;
const TWO_PI = JavaMath.PI * 2;
function clamp(val, min, max) {
return Math.min(Math.max(val, min), max);
}
function lerp(x, y, a) {
return (1 - a) * x + y * a;
}
function invLerp(x, y, a) {
return (a - x) / (y - x);
}
/**
* @param {number} averageTemp Output from calcAverageTemp
* @param {number} seaLevel The average Y level of the planet surface
* @param {number} playerY The current Y level of the player
* @param {number} calendarTicks Pass from the callback
* @param {number} tempRange Difference between the min/max temp at this latitude and the average.
* (ex: if average is 0c and min is -15 and max is 15, tempRange should be 15)
* @param {number} coreTemp Constant temperature at bedrock level
* @param {number} coreTempMult How much the coreTemp affects the bedrock level. 0 for a dead planet, 1 for the earth.
* @returns {number}
*/
function calcCurrentTemp(averageTemp, seaLevel, playerY, calendarTicks, tempRange, coreTemp, coreTempMult) {
let dayTicks = ((calendarTicks - SIX_TIMES_TICKS_IN_HOUR) % TICKS_IN_DAY);
let dayPercent = dayTicks / TICKS_IN_DAY
let tempDiff = Math.sin(dayPercent * TWO_PI) * tempRange;
if (playerY > seaLevel) {
// This is taken from TFC's OverworldClimateModel.java
let elevationTemp = clamp((playerY - seaLevel) * 0.16225, 0, 17.822);
return averageTemp - elevationTemp + tempDiff;
}
else if (playerY > 0) {
return averageTemp + (tempDiff * (playerY / seaLevel));
}
else {
let depthPercent = 1 - (playerY / -64);
let bedrockTemp = lerp(averageTemp, coreTemp, coreTempMult);
return lerp(bedrockTemp, averageTemp, depthPercent);
}
}
/**
* @param {number} playerZ The current Z level of the player
* @param {number} scale The size of the planet, from the south pole to the north (20k on earth with default TFC settings)
* @param {number} min The average value at the poles
* @param {number} max The average value at the equator
* @returns {number}
*/
function calcAverage(playerZ, scale, min, max) {
let relative = (playerZ / scale * -1) + 0.5;
// relative is now 1 for peak -z, 0 for peak +z
let smoothed = Math.cos(relative * JavaMath.PI);
// smoothed is now -1 for peak -z, 1 for peak +z
let halfDiff = (min - max) / -2;
let temp = (smoothed * halfDiff) - (halfDiff - max);
return temp;
}
// This will be fighting between TFC, which wants to melt everything when the average
// temp is above 0, and Ad Astra, which wants to freeze everything that isn't in an
// oxygenated bubble.
// Is there a way to disable TFC's system here?
// Alternatively, is there a way to tell if a block is oxygenated and then give it a different average temp?
// That'd let you grow tfc crops on other planets
TFCEvents.registerClimateModel(event => {
event.registerClimateModel('tfg:nether_climate', model => {
model.setCurrentTemperatureCalculation((level, pos, calendarTicks, daysInMonth) => {
return lerp(100, 25, pos.y / 128);
})
model.setAverageTemperatureCalculation((level, pos) => {
return lerp(100, 25, pos.y / 128);
})
model.setAverageRainfallCalculation((level, pos) => {
return lerp(-200, 200, pos.y / 128);
})
model.setAirFog((level, pos, calendarTicks) => 0)
model.setWaterFog((level, pos, calendarTicks) => 0.6)
model.setWindVector((block, calendarTicks) => event.newVec2(0, 0))
})
/*event.registerClimateModel('tfg:orbit_climate', model => {
// There's basically no heat diffusion in space so we can pretend this is your spacesuit temp
model.setCurrentTemperatureCalculation((level, pos, calendarTicks, daysInMonth) => 15)
model.setAverageTemperatureCalculation((level, pos) => -270)
model.setAverageRainfallCalculation((level, pos) => 0)
model.setAirFog((level, pos, calendarTicks) => 0)
model.setWaterFog((level, pos, calendarTicks) => 0.25)
model.setWindVector((block, calendarTicks) => event.newVec2(0, 0))
})
event.registerClimateModel('tfg:moon_climate', model => {
// A source says the moon's equator is 120c at day and -130c at night
model.setCurrentTemperatureCalculation((level, pos, calendarTicks, daysInMonth) => {
return calcCurrentTemp(-5, 60, pos.y, calendarTicks, 125, 0, 0)
})
model.setAverageTemperatureCalculation((level, pos) => -5)
model.setAverageRainfallCalculation((level, pos) => 0)
model.setAirFog((level, pos, calendarTicks) => 0)
model.setWaterFog((level, pos, calendarTicks) => 0.25)
model.setWindVector((block, calendarTicks) => event.newVec2(0, 0))
})
event.registerClimateModel('tfg:mars_climate', model => {
model.setCurrentTemperatureCalculation((level, pos, calendarTicks, daysInMonth) => {
let avgTemp = calcAverage(pos.z, 10000, -110, -15);
return calcCurrentTemp(avgTemp, 65, pos.y, calendarTicks, 45, -10, 0.5);
})
model.setAverageTemperatureCalculation((level, pos) => {
// Earth is 10k to each pole, and mars is about half as big as earth, so 5k to each pole sounds good
return calcAverage(pos.z, 10000, -110, -15);
})
model.setAverageRainfallCalculation((level, pos) => {
// irl mars' poles have a snowfall of 0.13mm but that's barely noticeable here.
// Use a negative rainfall to stop it snowing closer to the equator. TFC clamps negatives to zero so it's fine
return calcAverage(pos.z, 10000, 13, -25)
})
model.setAirFog((level, pos, calendarTicks) => 0)
model.setWaterFog((level, pos, calendarTicks) => 0.25)
model.setWindVector((block, calendarTicks) => event.newVec2(0.25, 0.25))
})*/
})

View file

@ -0,0 +1,63 @@
// priority: 0
const registerTFCTagPrefixes = (event) => {
TagPrefix.ORES.remove(TagPrefix.ore)
TagPrefix.ORES.remove(TagPrefix.oreDeepslate)
TagPrefix.ORES.remove(TagPrefix.oreTuff)
TagPrefix.ORES.remove(TagPrefix.oreSand)
TagPrefix.ORES.remove(TagPrefix.oreRedSand)
TagPrefix.ORES.remove(TagPrefix.oreRedGranite)
TagPrefix.ORES.remove(TagPrefix.oreMarble)
TagPrefix.ORES.remove(TagPrefix.oreGravel)
TagPrefix.ORES.remove(TagPrefix.oreEndstone)
TagPrefix.ORES.remove(TagPrefix.oreNetherrack)
TagPrefix.ORES.remove(TagPrefix.oreBlackstone)
TagPrefix.ORES.remove(TagPrefix.oreBasalt)
TagPrefix.ORES.remove(TagPrefix.oreAndesite)
TagPrefix.ORES.remove(TagPrefix.oreDiorite)
TagPrefix.ORES.remove(TagPrefix.oreGranite)
global.TFC_STONE_TYPES.forEach(stoneTypeName => {
const material = GTCEuAPI.materialManager.getMaterial(stoneTypeName)
event.create(`${stoneTypeName}`, 'ore')
.stateSupplier(() => Block.getBlock('minecraft:stone').defaultBlockState())
.baseModelLocation(`tfc:block/rock/raw/${stoneTypeName}`)
.unificationEnabled(true)
.materialSupplier(() => material)
.materialIconType(GTMaterialIconType.ore)
.generationCondition(ItemGenerationCondition.hasOreProperty)
})
// Custom stone types
// Can't use 'blackstone' for whatever reason -- GTM has its own
// blackstone ore type but it doesn't seem to work at all?
// This works around that
event.create('pyroxenite', 'ore')
.stateSupplier(() => Block.getBlock('minecraft:blackstone').defaultBlockState())
.baseModelLocation('minecraft:block/blackstone')
.unificationEnabled(true)
.materialIconType(GTMaterialIconType.ore)
.generationCondition(ItemGenerationCondition.hasOreProperty)
.materialSupplier(() => GTMaterials.Blackstone)
event.create('dripstone', 'ore')
.stateSupplier(() => Block.getBlock('minecraft:dripstone_block').defaultBlockState())
.baseModelLocation('minecraft:block/dripstone_block')
.unificationEnabled(true)
.materialIconType(GTMaterialIconType.ore)
.generationCondition(ItemGenerationCondition.hasOreProperty)
// Redefine deepslate so it has the correct sound effects (yes I fixed this in GTM as well)
event.create('deepslate', 'ore')
.stateSupplier(() => Block.getBlock('minecraft:deepslate').defaultBlockState())
.baseModelLocation('minecraft:block/deepslate')
.unificationEnabled(true)
.materialIconType(GTMaterialIconType.ore)
.generationCondition(ItemGenerationCondition.hasOreProperty)
.materialSupplier(() => GTMaterials.Deepslate)
}