diff --git a/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e b/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e index 342b88ee..a7e3143d 100644 --- a/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e +++ b/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e @@ -1,2 +1,2 @@ -// 1.19.2 2023-09-30T14:59:41.5616989 Create: The Factory Must Grow's lang merger -edc972fa77e26fb6efb1cae553a9252d3b84e6d7 assets/tfmg/lang/en_us.json +// 1.19.2 2023-10-08T21:01:08.3213175 Create: The Factory Must Grow's lang merger +57fee01fa3d508c93985417faba6daa1c69d4dd7 assets/tfmg/lang/en_us.json diff --git a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a index 49067c8c..aaa173b5 100644 --- a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a +++ b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a @@ -1,8 +1,10 @@ -// 1.19.2 2023-09-28T15:00:28.8610672 Registrate Provider for tfmg [Recipes, Advancements, Loot tables, Tags (blocks), Tags (items), Tags (fluids), Tags (entity_types), Blockstates, Item models, Lang (en_us/en_ud)] +// 1.19.2 2023-10-08T21:01:08.324319 Registrate Provider for tfmg [Recipes, Advancements, Loot tables, Tags (blocks), Tags (items), Tags (fluids), Tags (entity_types), Blockstates, Item models, Lang (en_us/en_ud)] b7f5146505c40c08cdea7ad01fa99048b7ac5451 assets/tfmg/blockstates/aluminum_block.json 933485fa587fccc649b4cbe8f76f15e590cc8bb1 assets/tfmg/blockstates/bauxite.json 2b53ff8e880d35a42388584cb3ca896c55bfaf95 assets/tfmg/blockstates/bauxite_pillar.json 83154b3fd031e4e10e1103d4befc800a82da4bbe assets/tfmg/blockstates/blast_furnace_output.json +06919cd6d4a6a91ca37c30aebbb68c51feab4f74 assets/tfmg/blockstates/casting_basin.json +5771fe31474df0e15c3a2756bac1b31a7d898868 assets/tfmg/blockstates/casting_spout.json 9ca537517fb8baeff3d4e4137c93aebd6b874c81 assets/tfmg/blockstates/cast_iron_block.json e13ba2fa789c784e4b7cfec3dd4603e29152387e assets/tfmg/blockstates/cast_iron_distillation_controller.json 61bcb8f09523c05fe8ee07a4b8b71a59e98393fe assets/tfmg/blockstates/cast_iron_distillation_output.json @@ -39,6 +41,7 @@ a8f81ce72c3f074ffef304b238ae805f3b4ea763 assets/tfmg/blockstates/layered_bauxite d3ba2682652fd44337d1f82ec382df17611fabe1 assets/tfmg/blockstates/liquid_plastic.json 2dc4b1da2bee0275cbb13ef89003d56f62d4443d assets/tfmg/blockstates/lubrication_oil.json 6c819d5f63ca53146d069ba0d00b3e1b10391a68 assets/tfmg/blockstates/machine_input.json +3dff9e1ec59415779195d2abfa9f07bc17b428a1 assets/tfmg/blockstates/molten_metal.json ebd6804b999acea36abbf07c2381ee6dee0d7a16 assets/tfmg/blockstates/napalm.json 0f33dc6b2a736164b17f416ce7d127c87bfb6441 assets/tfmg/blockstates/napalm_bomb.json 89f2902010903aad686571ef37c781b111147456 assets/tfmg/blockstates/naphtha.json @@ -66,8 +69,8 @@ e29906d296994a13fefc2beb22f7693e1027dd1b assets/tfmg/blockstates/steel_fluid_val 71b4c68d8a02062252c4dfde41650b7667d8c0ca assets/tfmg/blockstates/steel_sheetmetal.json 47b56dad1f2715aae7430b5f9acb1d51a26cf562 assets/tfmg/blockstates/steel_smart_fluid_pipe.json 942bb86fa92b3c40fc535dccdd2e9f3b79a36d92 assets/tfmg/blockstates/surface_scanner.json -2c438721675e87e549f147887e3d0604acae4e20 assets/tfmg/lang/en_ud.json -eda6d43bb8bd4174ddbfa181989dce755756e941 assets/tfmg/lang/en_us.json +4ac8f2584be9abd987a4cd0516a5dc6cf08b5f58 assets/tfmg/lang/en_ud.json +5280ab5d23d323e2d440c1baf054e5d7f33f94ab assets/tfmg/lang/en_us.json 9e6a6b62f5e7528c4e4d4f72f3510edcd8f0c078 assets/tfmg/models/block/aluminum_block.json 5a4c785e8d8394ccd125732c0017459648574c4e assets/tfmg/models/block/bauxite_natural_0.json 4ace0da00498fcbb9ddfdf321767b40b095c8778 assets/tfmg/models/block/bauxite_natural_1.json @@ -185,6 +188,9 @@ f685ca653c8e197986b1ac8f43297989816d39d2 assets/tfmg/models/item/aluminum_ingot. 4ace0da00498fcbb9ddfdf321767b40b095c8778 assets/tfmg/models/item/bauxite.json 41091873d85bac787e4752d0ff81189432f1e28e assets/tfmg/models/item/bauxite_pillar.json 8ef0374ff08be7e1501c64fce1e075144e0c070f assets/tfmg/models/item/blast_furnace_output.json +a846fbfd51826403a8695e89fccaa9d54a7e3ea6 assets/tfmg/models/item/block_mold.json +1e73706492a2cc569bb603443d56b2e9773b9c6b assets/tfmg/models/item/casting_basin.json +94fd821fec37d1f451c1094d19ead45ed8c98f45 assets/tfmg/models/item/casting_spout.json ec38882fb9010884823d6d6afa604f8a6512d279 assets/tfmg/models/item/cast_iron_block.json 25acd7ba8827401619c5faf7bdbe60228b411864 assets/tfmg/models/item/cast_iron_distillation_controller.json fc48286f0e70651f3d5a915558c3c91ae3ad0da6 assets/tfmg/models/item/cast_iron_distillation_output.json @@ -216,6 +222,7 @@ ed2830b2988403aebaca633b2e315878b41f7503 assets/tfmg/models/item/gasoline_bucket 3fdff9e88db39939ee31968358eb51c060006766 assets/tfmg/models/item/heavy_machinery_casing.json f3bea42a905b7df9395bda18f751e2ee0c023e65 assets/tfmg/models/item/heavy_oil_bucket.json 81bf095f356d9dc74a83af78b860ef8d3aed9b72 assets/tfmg/models/item/industrial_pipe.json +858a4fb7e2e1874fc4e5f018453ccc8d272dbc03 assets/tfmg/models/item/ingot_mold.json 8996fe57623ded9433d6766e80a39e41a2aba1ca assets/tfmg/models/item/kerosene_bucket.json c0f668fca568bc4c35aba97d9ac93986720e501f assets/tfmg/models/item/layered_bauxite.json ee1682c21054b9a9ffde5983141d49e8177f9a2a assets/tfmg/models/item/lead_block.json @@ -289,7 +296,7 @@ d26621b9617890011a68780cf7ab40fbb4658edc data/forge/tags/items/storage_blocks/le 63c4a8d8e713db70730e766f1a10f8dd9072f98f data/minecraft/tags/blocks/dripstone_replaceable_blocks.json 63c4a8d8e713db70730e766f1a10f8dd9072f98f data/minecraft/tags/blocks/lush_ground_replaceable.json 694d1673a052cf6c604fd75f5f0b8954a04a05e3 data/minecraft/tags/blocks/mineable/axe.json -02cc402fd90edb75d6a0e43851d4eca2912bd0bc data/minecraft/tags/blocks/mineable/pickaxe.json +4f5ce2d2b247c3271434a846a5172de74ac10b39 data/minecraft/tags/blocks/mineable/pickaxe.json 63c4a8d8e713db70730e766f1a10f8dd9072f98f data/minecraft/tags/blocks/moss_replaceable.json f67e51a16b6d140324ca0201f1b05e672eb63774 data/minecraft/tags/blocks/needs_iron_tool.json 755548d9019c1bb26a568488912ebfdf399e02d2 data/minecraft/tags/blocks/needs_stone_tool.json @@ -341,6 +348,8 @@ a4b393a2526bd10fa38095ac80769f913f139889 data/tfmg/loot_tables/blocks/aluminum_b 56d114d40ea3160b5c06cf9cfaa2e5107543c460 data/tfmg/loot_tables/blocks/bauxite.json 473b0effd9a768189aa232855cd09e7b380c3adc data/tfmg/loot_tables/blocks/bauxite_pillar.json 42f0a002820ca15e79fbc28e45e0f34638e9aeab data/tfmg/loot_tables/blocks/blast_furnace_output.json +b856690500dccf0e5407bcb45e057710259f48e3 data/tfmg/loot_tables/blocks/casting_basin.json +5627226e6bd089259395af9338db044278133033 data/tfmg/loot_tables/blocks/casting_spout.json 60857d034446187e758de87644a80a7bc4d6b150 data/tfmg/loot_tables/blocks/cast_iron_block.json 300a96dcae25ba9bc085ee75f066b4ad2590b6e0 data/tfmg/loot_tables/blocks/cast_iron_distillation_controller.json 24517e07383f7a7eb8651f58721cf9f6f49393c0 data/tfmg/loot_tables/blocks/cast_iron_distillation_output.json diff --git a/src/generated/resources/assets/tfmg/blockstates/casting_basin.json b/src/generated/resources/assets/tfmg/blockstates/casting_basin.json new file mode 100644 index 00000000..fe8e1295 --- /dev/null +++ b/src/generated/resources/assets/tfmg/blockstates/casting_basin.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "tfmg:block/casting_basin/block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/blockstates/casting_spout.json b/src/generated/resources/assets/tfmg/blockstates/casting_spout.json new file mode 100644 index 00000000..5663f28e --- /dev/null +++ b/src/generated/resources/assets/tfmg/blockstates/casting_spout.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "tfmg:block/casting_spout/block" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/blockstates/molten_metal.json b/src/generated/resources/assets/tfmg/blockstates/molten_metal.json new file mode 100644 index 00000000..2c8f02f0 --- /dev/null +++ b/src/generated/resources/assets/tfmg/blockstates/molten_metal.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/air" + } + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/lang/en_ud.json b/src/generated/resources/assets/tfmg/lang/en_ud.json index cb4b4bbc..94460135 100644 --- a/src/generated/resources/assets/tfmg/lang/en_ud.json +++ b/src/generated/resources/assets/tfmg/lang/en_ud.json @@ -6,6 +6,8 @@ "block.tfmg.cast_iron_block": "uoɹI ʇsɐƆ ɟo ʞɔoןᗺ", "block.tfmg.cast_iron_distillation_controller": "ɹǝןןoɹʇuoƆ uoıʇɐןןıʇsıᗡ uoɹI ʇsɐƆ", "block.tfmg.cast_iron_distillation_output": "ʇndʇnO uoıʇɐןןıʇsıᗡ uoɹI ʇsɐƆ", + "block.tfmg.casting_basin": "uısɐᗺ buıʇsɐƆ", + "block.tfmg.casting_spout": "ʇnodS buıʇsɐƆ", "block.tfmg.coal_coke_block": "ǝʞoƆ ןɐoƆ ɟo ʞɔoןᗺ", "block.tfmg.coke_oven": "uǝʌO ǝʞoƆ", "block.tfmg.concrete": "ǝʇǝɹɔuoƆ", @@ -39,6 +41,7 @@ "block.tfmg.liquid_plastic": "ɔıʇsɐןԀ pınbıꞀ", "block.tfmg.lubrication_oil": "ןıO uoıʇɐɔıɹqnꞀ", "block.tfmg.machine_input": "ʇnduI ǝuıɥɔɐW", + "block.tfmg.molten_metal": "ןɐʇǝW uǝʇןoW", "block.tfmg.napalm": "ɯןɐdɐN", "block.tfmg.napalm_bomb": "qɯoᗺ ɯןɐdɐN", "block.tfmg.naphtha": "ɐɥʇɥdɐN", @@ -92,6 +95,7 @@ "fluid.tfmg.propane": "ǝuɐdoɹԀ", "fluid.tfmg.propylene": "ǝuǝןʎdoɹԀ", "item.tfmg.aluminum_ingot": "ʇobuI ɯnuıɯnןⱯ", + "item.tfmg.block_mold": "pןoW ʞɔoןᗺ", "item.tfmg.cast_iron_ingot": "ʇobuI uoɹI ʇsɐƆ", "item.tfmg.coal_coke": "ǝʞoƆ ןɐoƆ", "item.tfmg.coal_coke_dust": "ʇsnᗡ ǝʞoƆ ןɐoƆ", @@ -102,6 +106,7 @@ "item.tfmg.diesel_bucket": "ʇǝʞɔnᗺ ןǝsǝıᗡ", "item.tfmg.gasoline_bucket": "ʇǝʞɔnᗺ ǝuıןosɐ⅁", "item.tfmg.heavy_oil_bucket": "ʇǝʞɔnᗺ ןıO ʎʌɐǝH", + "item.tfmg.ingot_mold": "pןoW ʇobuI", "item.tfmg.kerosene_bucket": "ʇǝʞɔnᗺ ǝuǝsoɹǝʞ", "item.tfmg.lead_ingot": "ʇobuI pɐǝꞀ", "item.tfmg.liquid_concrete_bucket": "ʇǝʞɔnᗺ ǝʇǝɹɔuoƆ pınbıꞀ", diff --git a/src/generated/resources/assets/tfmg/lang/en_us.json b/src/generated/resources/assets/tfmg/lang/en_us.json index 618cd4f0..601081fe 100644 --- a/src/generated/resources/assets/tfmg/lang/en_us.json +++ b/src/generated/resources/assets/tfmg/lang/en_us.json @@ -9,6 +9,8 @@ "block.tfmg.cast_iron_block": "Block of Cast Iron", "block.tfmg.cast_iron_distillation_controller": "Cast Iron Distillation Controller", "block.tfmg.cast_iron_distillation_output": "Cast Iron Distillation Output", + "block.tfmg.casting_basin": "Casting Basin", + "block.tfmg.casting_spout": "Casting Spout", "block.tfmg.coal_coke_block": "Block of Coal Coke", "block.tfmg.coke_oven": "Coke Oven", "block.tfmg.concrete": "Concrete", @@ -42,6 +44,7 @@ "block.tfmg.liquid_plastic": "Liquid Plastic", "block.tfmg.lubrication_oil": "Lubrication Oil", "block.tfmg.machine_input": "Machine Input", + "block.tfmg.molten_metal": "Molten Metal", "block.tfmg.napalm": "Napalm", "block.tfmg.napalm_bomb": "Napalm Bomb", "block.tfmg.naphtha": "Naphtha", @@ -98,6 +101,7 @@ "fluid.tfmg.propylene": "Propylene", "item.tfmg.aluminum_ingot": "Aluminum Ingot", + "item.tfmg.block_mold": "Block Mold", "item.tfmg.cast_iron_ingot": "Cast Iron Ingot", "item.tfmg.coal_coke": "Coal Coke", "item.tfmg.coal_coke_dust": "Coal Coke Dust", @@ -108,6 +112,7 @@ "item.tfmg.diesel_bucket": "Diesel Bucket", "item.tfmg.gasoline_bucket": "Gasoline Bucket", "item.tfmg.heavy_oil_bucket": "Heavy Oil Bucket", + "item.tfmg.ingot_mold": "Ingot Mold", "item.tfmg.kerosene_bucket": "Kerosene Bucket", "item.tfmg.lead_ingot": "Lead Ingot", "item.tfmg.liquid_concrete_bucket": "Liquid Concrete Bucket", @@ -121,48 +126,6 @@ "item.tfmg.thermite_grenade": "Thermite Grenade", "item.tfmg.zinc_grenade": "Zinc Grenade", - "itemGroup.tfmg.base": "Create: The Factory Must Grow", - "itemGroup.tfmg.building": "Create: TFMG's Building Blocks", - - "create.goggles.misc.number": "%1$s", - "create.goggles.misc.dot_one": ".", - "create.goggles.misc.dot_two": "..", - "create.goggles.misc.dot_three": "...", - "create.goggles.fluid_in_tank": "Fluid In Tank:", - "create.goggles.surface_scanner.no_rotation": "No Rotation Provided", - "create.goggles.surface_scanner.no_deposit": "No Deposit Found", - "create.goggles.surface_scanner.deposit_found": "Found Deposit", - "create.goggles.surface_scanner.distance": "Distance: %1$s Blocks", - "create.goggles.surface_scanner.scanning_surface": "Scanning Surface", - "create.goggles.distillation_tower.status": "Distillation Tower Info:", - "create.goggles.distillation_tower.tank_not_found": "Steel Fluid Tank Not Found", - "create.goggles.distillation_tower.not_tall_enough": "Distillation Tower is Not Tall Enough", - "create.goggles.distillation_tower.level": "Distillation Tower Level: %1$s", - "create.goggles.distillation_tower.found_outputs": "Found Outputs: %1$s", - "create.goggles.distillation_tower.no_outputs": "No Output Blocks Found", - "create.goggles.blast_furnace.stats": "Blast Furnace:", - "create.goggles.blast_furnace.size_stats": "Size Stats:", - "create.goggles.blast_furnace.fuel_amount": "Fuel Amount: %1$s", - "create.goggles.blast_furnace.item_count": "Item Count: %1$s", - "create.goggles.blast_furnace.height": "Height: %1$s", - "create.goggles.blast_furnace.reinforcement_height": "Reinforcement Height: %1$s", - "create.goggles.blast_furnace.status.off": "Status: Off", - "create.goggles.blast_furnace.status.running": "Status: Running", - "create.goggles.blast_furnace.status.finished": "Status: Process Finished", - "create.goggles.blast_furnace.diameter.one": "Diameter: 1", - "create.goggles.blast_furnace.diameter.two": "Diameter: 2", - "create.goggles.misc.storage_info": "Storage Info:", - "create.goggles.coke_oven.status": "Coke Oven:", - "create.goggles.coke_oven.fluid_amount_output": "Fluid Amount In Internal Tank: %1$s mb", - "create.goggles.coke_oven.fluid_amount_exhaust": "Carbon Dioxide: %1$s mb", - "create.goggles.coke_oven.item_count": "Item Count In Internal Storage: %1$s", - "create.goggles.coke_oven.invalid": "Coke Oven Invalid", - "create.goggles.coke_oven.tank_full": "One of Internal Tanks Is Full", - "create.goggles.coke_oven.progress": "Progress: %1$s", - "create.goggles.misc.percent_symboll": "%", - "create.goggles.misc.percent_symbol": "%", - "create.goggles.blast_furnace.invalid": "Blast Furnace is Not Built Correctly", - "_": "->------------------------] UI & Messages [------------------------<-", diff --git a/src/generated/resources/assets/tfmg/models/item/block_mold.json b/src/generated/resources/assets/tfmg/models/item/block_mold.json new file mode 100644 index 00000000..a563477f --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/block_mold.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "tfmg:item/block_mold" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/models/item/casting_basin.json b/src/generated/resources/assets/tfmg/models/item/casting_basin.json new file mode 100644 index 00000000..55a81c97 --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/casting_basin.json @@ -0,0 +1,3 @@ +{ + "parent": "tfmg:block/casting_basin/block" +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/models/item/casting_spout.json b/src/generated/resources/assets/tfmg/models/item/casting_spout.json new file mode 100644 index 00000000..39f471a1 --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/casting_spout.json @@ -0,0 +1,3 @@ +{ + "parent": "tfmg:block/casting_spout/block" +} \ No newline at end of file diff --git a/src/generated/resources/assets/tfmg/models/item/ingot_mold.json b/src/generated/resources/assets/tfmg/models/item/ingot_mold.json new file mode 100644 index 00000000..c946a317 --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/ingot_mold.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "tfmg:item/ingot_mold" + } +} \ No newline at end of file diff --git a/src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json b/src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json index dcb005ab..f29e7b3a 100644 --- a/src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json +++ b/src/generated/resources/data/minecraft/tags/blocks/mineable/pickaxe.json @@ -20,6 +20,8 @@ "tfmg:fireproof_bricks", "tfmg:fireproof_brick_reinforcement", "tfmg:blast_furnace_output", + "tfmg:casting_basin", + "tfmg:casting_spout", "tfmg:coke_oven", "tfmg:steel_block", "tfmg:cast_iron_block", diff --git a/src/generated/resources/data/tfmg/loot_tables/blocks/casting_basin.json b/src/generated/resources/data/tfmg/loot_tables/blocks/casting_basin.json new file mode 100644 index 00000000..16e10f00 --- /dev/null +++ b/src/generated/resources/data/tfmg/loot_tables/blocks/casting_basin.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "tfmg:casting_basin" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/generated/resources/data/tfmg/loot_tables/blocks/casting_spout.json b/src/generated/resources/data/tfmg/loot_tables/blocks/casting_spout.json new file mode 100644 index 00000000..6005a5fb --- /dev/null +++ b/src/generated/resources/data/tfmg/loot_tables/blocks/casting_spout.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "tfmg:casting_spout" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/blocks/concrete/formwork/FormWorkBlockEntity.java b/src/main/java/com/drmangotea/tfmg/blocks/concrete/formwork/FormWorkBlockEntity.java index d737e64c..891279a6 100644 --- a/src/main/java/com/drmangotea/tfmg/blocks/concrete/formwork/FormWorkBlockEntity.java +++ b/src/main/java/com/drmangotea/tfmg/blocks/concrete/formwork/FormWorkBlockEntity.java @@ -1,7 +1,9 @@ package com.drmangotea.tfmg.blocks.concrete.formwork; import com.drmangotea.tfmg.blocks.machines.TFMGMachineBlockEntity; +import com.drmangotea.tfmg.registry.TFMGBlocks; import com.drmangotea.tfmg.registry.TFMGFluids; +import com.simibubi.create.Create; import com.simibubi.create.foundation.fluid.SmartFluidTank; import com.simibubi.create.foundation.utility.animation.LerpedFloat; import net.minecraft.core.BlockPos; @@ -22,6 +24,8 @@ public class FormWorkBlockEntity extends TFMGMachineBlockEntity { public boolean south = true; public boolean bottom = true; + public int timer = -1; + protected FluidTank tankInventory; @@ -49,6 +53,26 @@ public class FormWorkBlockEntity extends TFMGMachineBlockEntity { @Override public void tick() { + + + + if(tankInventory.getFluidAmount()==tankInventory.getCapacity()){ + if(timer==-1) { + timer = 180 * 24; + }else { + + timer--; + + if(timer==0){ + level.setBlock(getBlockPos(), TFMGBlocks.CONCRETE.getDefaultState(),1); + } + } + + + } else + timer = -1; + + super.tick(); fluidLevel.chase(tankInventory.getFluidAmount(), 0.3f, LerpedFloat.Chaser.EXP); fluidLevel.tickChaser(); @@ -171,6 +195,8 @@ public class FormWorkBlockEntity extends TFMGMachineBlockEntity { protected void read(CompoundTag compound, boolean clientPacket) { super.read(compound, clientPacket); + timer = compound.getInt("Timer"); + bottom = compound.getBoolean("Bottom"); east = compound.getBoolean("East"); @@ -188,6 +214,8 @@ public class FormWorkBlockEntity extends TFMGMachineBlockEntity { super.write(compound, clientPacket); + compound.putInt("Timer", timer); + compound.putBoolean("Bottom", bottom); compound.putBoolean("East", east); diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/blast_furnace/BlastFurnaceOutputBlockEntity.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/blast_furnace/BlastFurnaceOutputBlockEntity.java index 1ba862c4..d51453d5 100644 --- a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/blast_furnace/BlastFurnaceOutputBlockEntity.java +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/blast_furnace/BlastFurnaceOutputBlockEntity.java @@ -491,6 +491,7 @@ public class BlastFurnaceOutputBlockEntity extends TFMGMachineBlockEntity implem super.read(compound, clientPacket); inputInventory.deserializeNBT(compound.getCompound("InputItems")); fuelInventory.deserializeNBT(compound.getCompound("Fuel")); + timer = compound.getInt("Timer"); } @Override @@ -499,6 +500,7 @@ public class BlastFurnaceOutputBlockEntity extends TFMGMachineBlockEntity implem compound.put("InputItems", inputInventory.serializeNBT()); compound.put("Fuel", fuelInventory.serializeNBT()); + compound.putInt("Timer", timer); } @Override diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlock.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlock.java new file mode 100644 index 00000000..ebf8ae87 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlock.java @@ -0,0 +1,83 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin; + + +import com.drmangotea.tfmg.blocks.machines.metal_processing.coke_oven.CokeOvenBlock; +import com.drmangotea.tfmg.registry.TFMGBlockEntities; +import com.drmangotea.tfmg.registry.TFMGItems; +import com.simibubi.create.content.equipment.wrench.IWrenchable; +import com.simibubi.create.foundation.block.IBE; +import net.minecraft.core.BlockPos; +import net.minecraft.world.InteractionHand; +import net.minecraft.world.InteractionResult; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.Items; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.properties.EnumProperty; +import net.minecraft.world.phys.BlockHitResult; + +public class CastingBasinBlock extends Block implements IBE, IWrenchable { + + public static final EnumProperty MOLD_TYPE = EnumProperty.create("mold_type", CastingBasinBlockEntity.MoldType.class); + + public CastingBasinBlock(Properties p_49795_) { + super(p_49795_); + registerDefaultState(defaultBlockState().setValue(MOLD_TYPE, CastingBasinBlockEntity.MoldType.NONE)); + } + + @Override + public InteractionResult use(BlockState state, Level level, BlockPos pos, Player player, InteractionHand interactionHand, BlockHitResult blockHitResult) { + CastingBasinBlockEntity be; + + + + if(level.getBlockEntity(pos) instanceof CastingBasinBlockEntity) { + be = (CastingBasinBlockEntity) level.getBlockEntity(pos); + }else return InteractionResult.PASS; + + if(be ==null) + return InteractionResult.PASS; + /// + + if(!be.tank1.isEmpty()) + return InteractionResult.PASS; + + if(player.getItemInHand(interactionHand).is(Items.AIR)&&!(((CastingBasinBlockEntity) level.getBlockEntity(pos)).moldInventory.isEmpty())){ + player.setItemInHand(interactionHand,new ItemStack(be.moldInventory.getStackInSlot(0).getItem(),1)); + ((CastingBasinBlockEntity) level.getBlockEntity(pos)).moldInventory.getStackInSlot(0).shrink(1); + + + return InteractionResult.SUCCESS; + } + + + /// + if(player.getItemInHand(interactionHand).getItem() instanceof CastingMoldItem&&((CastingBasinBlockEntity) level.getBlockEntity(pos)).moldInventory.isEmpty()){ + ((CastingBasinBlockEntity) level.getBlockEntity(pos)).moldInventory.setStackInSlot(0, new ItemStack(player.getItemInHand(interactionHand).getItem(),1)); + player.getItemInHand(interactionHand).shrink(1); + + + return InteractionResult.SUCCESS; + } + return InteractionResult.PASS; + } + @Override + protected void createBlockStateDefinition(StateDefinition.Builder pBuilder) { + pBuilder.add(MOLD_TYPE); + super.createBlockStateDefinition(pBuilder); + } + + @Override + public Class getBlockEntityClass() { + return CastingBasinBlockEntity.class; + } + + @Override + public BlockEntityType getBlockEntityType() { + return TFMGBlockEntities.CASTING_BASIN.get(); + } +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlockEntity.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlockEntity.java new file mode 100644 index 00000000..43a1408f --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinBlockEntity.java @@ -0,0 +1,317 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin; + +import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.blocks.machines.TFMGMachineBlockEntity; +import com.drmangotea.tfmg.recipes.casting.CastingRecipe; +import com.simibubi.create.content.equipment.goggles.IHaveGoggleInformation; +import com.simibubi.create.foundation.blockEntity.behaviour.BlockEntityBehaviour; +import com.simibubi.create.foundation.fluid.CombinedTankWrapper; +import com.simibubi.create.foundation.item.SmartInventory; +import com.simibubi.create.foundation.recipe.RecipeFinder; +import com.simibubi.create.foundation.utility.Lang; +import com.simibubi.create.foundation.utility.LangBuilder; +import net.minecraft.ChatFormatting; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.nbt.CompoundTag; +import net.minecraft.network.chat.Component; +import net.minecraft.util.StringRepresentable; +import net.minecraft.world.Container; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.crafting.Recipe; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.material.Fluids; +import net.minecraftforge.common.capabilities.Capability; +import net.minecraftforge.common.util.LazyOptional; +import net.minecraftforge.fluids.FluidStack; +import net.minecraftforge.fluids.capability.CapabilityFluidHandler; +import net.minecraftforge.fluids.capability.IFluidHandler; +import net.minecraftforge.items.CapabilityItemHandler; +import net.minecraftforge.items.IItemHandlerModifiable; +import net.minecraftforge.items.wrapper.CombinedInvWrapper; + +import javax.annotation.Nonnull; +import java.util.List; +import java.util.Optional; + +import static com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingBasinBlock.MOLD_TYPE; + +public class CastingBasinBlockEntity extends TFMGMachineBlockEntity implements IHaveGoggleInformation { + + + public MoldType type; + + private CastingRecipe recipe; + + public int timer = -1; + + public SmartInventory outputInventory; + public SmartInventory moldInventory; + + public LazyOptional itemCapability; + + private static final Object CastingRecipesKey = new Object(); + + public CastingBasinBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + + outputInventory = new SmartInventory(1, this) + .withMaxStackSize(64); + + moldInventory = new SmartInventory(1, this) + .withMaxStackSize(1); + + itemCapability = LazyOptional.of(() -> new CombinedInvWrapper(outputInventory,moldInventory)); + tank1.getPrimaryHandler().setCapacity(4000); + tank2.forbidExtraction(); + tank2.forbidInsertion(); + + moldInventory.forbidExtraction(); + moldInventory.forbidInsertion(); + outputInventory.forbidInsertion(); + } + + + public void tick(){ + super.tick(); + type = getBlockState().getValue(MOLD_TYPE); + + + findRecipe(); + // + + setMold(); + + if(tank1.isEmpty()){ + setCapacity(); + } + + if(type==MoldType.NONE) + return; + + if(recipe==null) + return; + + if(outputInventory.getStackInSlot(0).getCount()!=0) + return; + + + if(tank1.getPrimaryHandler().getCapacity()==tank1.getPrimaryHandler().getFluidAmount()){ + + if(timer ==-1) { + //if(type==MoldType.BLOCK) + timer = recipe.getProcessingDuration(); + //if(type==MoldType.INGOT) + // timer = recipe.getProcessingDuration()/9; + + } + + if (timer >0) + timer--; + + if(timer == 0){ + + if(type==MoldType.INGOT) + outputInventory.setStackInSlot(0,recipe.getIngotResult()); + if(type==MoldType.BLOCK) + outputInventory.setStackInSlot(0,recipe.getBlockResult()); + + + tank1.getPrimaryHandler().setFluid(new FluidStack(Fluids.EMPTY,0)); + timer = -1; + } + + } + + } + + + public void setMold(){ + if(moldInventory.isEmpty()) + return; + + MoldType moldType = ((CastingMoldItem)moldInventory.getStackInSlot(0).getItem()).getType(); + MoldType oldMoldType = this.getBlockState().getValue(MOLD_TYPE); + if(moldType==oldMoldType) + return; + + level.setBlock(getBlockPos(),this.getBlockState().setValue(MOLD_TYPE,moldType),2); + type = getBlockState().getValue(MOLD_TYPE); + } + + public void findRecipe(){ + CombinedTankWrapper tankIn = new CombinedTankWrapper(tank1.getPrimaryHandler(),tank2.getPrimaryHandler()); + if (recipe == null || !recipe.matches(tankIn, level)) { + CastingRecipe recipe = getMatchingRecipes(); + if (recipe!=null) { + this.recipe = recipe; + sendData(); + } + } + } + + public void setCapacity(){ + if(type == null){ + if(tank1.getPrimaryHandler().getCapacity()<4000) + tank1.getPrimaryHandler().setCapacity(4000); + }else { + if(tank1.getPrimaryHandler().getCapacity()!=type.getRequiredFluidAmount()) + tank1.getPrimaryHandler().setCapacity(type.getRequiredFluidAmount()); + } + } + + protected CastingRecipe getMatchingRecipes() { + + + List> list = RecipeFinder.get(getRecipeCacheKey(), level, this::matchStaticFilters); + + + for(int i = 0; i < list.toArray().length;i++){ + CastingRecipe recipe = (CastingRecipe) list.get(i); + for(int y = 0; y < recipe.getFluidIngredients().get(0).getMatchingFluidStacks().toArray().length;y++) + if(tank1.getPrimaryHandler().getFluid().getFluid()==recipe.getFluidIngredients().get(0).getMatchingFluidStacks().get(y).getFluid()) + if(tank1.getPrimaryHandler().getFluidAmount()>=recipe.getFluidIngredients().get(0).getRequiredAmount()) + return recipe; + } + + return null; + } + @Override + @SuppressWarnings("removal") + public boolean addToGoggleTooltip(List tooltip, boolean isPlayerSneaking) { + + + + //--Fluid Info--// + LazyOptional handler = this.getCapability(CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY); + Optional resolve = handler.resolve(); + if (!resolve.isPresent()) + return false; + + IFluidHandler tank = resolve.get(); + if (tank.getTanks() == 0) + return false; + + LangBuilder mb = Lang.translate("generic.unit.millibuckets"); + + boolean isEmpty = true; + for (int i = 0; i < tank.getTanks(); i++) { + FluidStack fluidStack = tank.getFluidInTank(i); + if (fluidStack.isEmpty()) + continue; + + Lang.fluidName(fluidStack) + .style(ChatFormatting.GRAY) + .forGoggles(tooltip, 1); + + Lang.builder() + .add(Lang.number(fluidStack.getAmount()) + .add(mb) + .style(ChatFormatting.DARK_GREEN)) + .text(ChatFormatting.GRAY, " / ") + .add(Lang.number(tank.getTankCapacity(i)) + .add(mb) + .style(ChatFormatting.DARK_GRAY)) + .forGoggles(tooltip, 1); + + isEmpty = false; + } + + if (tank.getTanks() > 1) { + if (isEmpty) + tooltip.remove(tooltip.size() - 1); + return true; + } + + if (!isEmpty) + return true; + + Lang.translate("gui.goggles.fluid_container.capacity") + .add(Lang.number(tank.getTankCapacity(0)) + .add(mb) + .style(ChatFormatting.DARK_GREEN)) + .style(ChatFormatting.DARK_GRAY) + .forGoggles(tooltip, 1); + + + return true; + } + protected boolean matchStaticFilters(Recipe r) { + return r instanceof CastingRecipe; + } + + @Override + protected void read(CompoundTag compound, boolean clientPacket) { + super.read(compound, clientPacket); + + outputInventory.deserializeNBT(compound.getCompound("OutputItems")); + moldInventory.deserializeNBT(compound.getCompound("CurrentMold")); + + + timer = compound.getInt("Timer"); + + + } + + @Override + public void write(CompoundTag compound, boolean clientPacket) { + super.write(compound, clientPacket); + + compound.put("OutputItems", outputInventory.serializeNBT()); + compound.put("CurrentMold", moldInventory.serializeNBT()); + compound.putInt("Timer", timer); + + + + } + @Override + public void invalidate() { + super.invalidate(); + itemCapability.invalidate(); + } + @Nonnull + @Override + @SuppressWarnings("removal") + public LazyOptional getCapability(@Nonnull Capability cap, Direction side) { + if (cap == CapabilityItemHandler.ITEM_HANDLER_CAPABILITY) + return itemCapability.cast(); + if (cap == CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY) + return fluidCapability.cast(); + return super.getCapability(cap, side); + } + protected Object getRecipeCacheKey() { + return CastingRecipesKey; + } + @Override + public void addBehaviours(List behaviours) { + super.addBehaviours(behaviours); + } + + + public enum MoldType implements StringRepresentable { + INGOT("ingot",112), + BLOCK("block",1000), + + NONE("none", 4000); + + + + private final String name; + + private final int fluidAmountNeeded; + + MoldType(String name, int amountNeeded) { + this.name = name; + this.fluidAmountNeeded = amountNeeded; + } + + public int getRequiredFluidAmount(){return this.fluidAmountNeeded;} + + @Override + public String getSerializedName() { + return this.name; + } + + } +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinRenderer.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinRenderer.java new file mode 100644 index 00000000..e20e29c8 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingBasinRenderer.java @@ -0,0 +1,4 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin; + +public class CastingBasinRenderer { +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingMoldItem.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingMoldItem.java new file mode 100644 index 00000000..475214b0 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_basin/CastingMoldItem.java @@ -0,0 +1,19 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin; + +import net.minecraft.world.item.Item; + +public class CastingMoldItem extends Item { + + + private final CastingBasinBlockEntity.MoldType type; + public CastingMoldItem(Properties p_41383_, CastingBasinBlockEntity.MoldType type) { + super(p_41383_); + this.type = type; + } + + + public CastingBasinBlockEntity.MoldType getType(){ + return this.type; + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlock.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlock.java new file mode 100644 index 00000000..8199b0ca --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlock.java @@ -0,0 +1,23 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout; + + +import com.drmangotea.tfmg.registry.TFMGBlockEntities; +import com.simibubi.create.foundation.block.IBE; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.entity.BlockEntityType; + +public class CastingSpoutBlock extends Block implements IBE { + public CastingSpoutBlock(Properties p_49795_) { + super(p_49795_); + } + + @Override + public Class getBlockEntityClass() { + return CastingSpoutBlockEntity.class; + } + + @Override + public BlockEntityType getBlockEntityType() { + return TFMGBlockEntities.CASTING_SPOUT.get(); + } +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlockEntity.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlockEntity.java new file mode 100644 index 00000000..ac058e4c --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutBlockEntity.java @@ -0,0 +1,152 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout; + +import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.blocks.machines.TFMGMachineBlockEntity; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingBasinBlockEntity; +import com.simibubi.create.content.fluids.tank.FluidTankBlockEntity; +import com.simibubi.create.foundation.utility.Lang; +import com.simibubi.create.foundation.utility.LangBuilder; +import com.simibubi.create.foundation.utility.animation.LerpedFloat; +import net.minecraft.ChatFormatting; +import net.minecraft.core.BlockPos; +import net.minecraft.network.chat.Component; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraftforge.common.util.LazyOptional; +import net.minecraftforge.fluids.FluidStack; +import net.minecraftforge.fluids.capability.CapabilityFluidHandler; +import net.minecraftforge.fluids.capability.IFluidHandler; + +import java.util.List; +import java.util.Optional; + +public class CastingSpoutBlockEntity extends TFMGMachineBlockEntity { + + CastingBasinBlockEntity basin; + + public boolean isRunning=false; + + public LerpedFloat movement = LerpedFloat.linear(); + public CastingSpoutBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + + tank2.forbidInsertion(); + tank2.forbidExtraction(); + tank1.forbidExtraction(); + + + } + public void tick(){ + super.tick(); + + if(isRunning) { + movement.chase(0.03, 0.1f, LerpedFloat.Chaser.EXP); + }else + movement.chase(0, 0.1f, LerpedFloat.Chaser.EXP); + movement.tickChaser(); + + + if(tank1.isEmpty()) + { + isRunning = false; + return; + } + + if(level.getBlockEntity(getBlockPos().below(2)) instanceof CastingBasinBlockEntity){ + basin = (CastingBasinBlockEntity) level.getBlockEntity(getBlockPos().below(2)); + }else { + isRunning = false; + return; + } + if(basin.moldInventory.isEmpty()) + { + isRunning = false; + return; + } + if(basin.tank1.getPrimaryHandler().getFluidAmount()==basin.tank1.getPrimaryHandler().getCapacity()) + { + isRunning = false; + return; + } + + if(basin.outputInventory.getStackInSlot(0).getCount()!=0) + { + isRunning = false; + return; + } + + if(basin.tank1.getPrimaryHandler().getCapacity()==4000) + { + isRunning = false; + return; + } + + + basin.tank1.getPrimaryHandler().setFluid(new FluidStack(tank1.getPrimaryHandler().getFluid().getFluid(),basin.tank1.getPrimaryHandler().getFluidAmount()+1)); + tank1.getPrimaryHandler().drain(1, IFluidHandler.FluidAction.EXECUTE); + isRunning = true; + + } + + @Override + @SuppressWarnings("removal") + public boolean addToGoggleTooltip(List tooltip, boolean isPlayerSneaking) { + + + + //--Fluid Info--// + LazyOptional handler = this.getCapability(CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY); + Optional resolve = handler.resolve(); + if (!resolve.isPresent()) + return false; + + IFluidHandler tank = resolve.get(); + if (tank.getTanks() == 0) + return false; + + LangBuilder mb = Lang.translate("generic.unit.millibuckets"); + + boolean isEmpty = true; + for (int i = 0; i < tank.getTanks(); i++) { + FluidStack fluidStack = tank.getFluidInTank(i); + if (fluidStack.isEmpty()) + continue; + + Lang.fluidName(fluidStack) + .style(ChatFormatting.GRAY) + .forGoggles(tooltip, 1); + + Lang.builder() + .add(Lang.number(fluidStack.getAmount()) + .add(mb) + .style(ChatFormatting.DARK_GREEN)) + .text(ChatFormatting.GRAY, " / ") + .add(Lang.number(tank.getTankCapacity(i)) + .add(mb) + .style(ChatFormatting.DARK_GRAY)) + .forGoggles(tooltip, 1); + + isEmpty = false; + } + + if (tank.getTanks() > 1) { + if (isEmpty) + tooltip.remove(tooltip.size() - 1); + return true; + } + + if (!isEmpty) + return true; + + Lang.translate("gui.goggles.fluid_container.capacity") + .add(Lang.number(tank.getTankCapacity(0)) + .add(mb) + .style(ChatFormatting.DARK_GREEN)) + .style(ChatFormatting.DARK_GRAY) + .forGoggles(tooltip, 1); + + + return true; + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutRenderer.java b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutRenderer.java new file mode 100644 index 00000000..4aa618c3 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/blocks/machines/metal_processing/casting_spout/CastingSpoutRenderer.java @@ -0,0 +1,102 @@ +package com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout; + + +import com.drmangotea.tfmg.registry.TFMGPartialModels; +import com.jozufozu.flywheel.core.PartialModel; +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.simibubi.create.AllPartialModels; +import com.simibubi.create.foundation.blockEntity.behaviour.fluid.SmartFluidTankBehaviour; +import com.simibubi.create.foundation.blockEntity.behaviour.fluid.SmartFluidTankBehaviour.TankSegment; +import com.simibubi.create.foundation.blockEntity.renderer.SafeBlockEntityRenderer; +import com.simibubi.create.foundation.fluid.FluidRenderer; +import com.simibubi.create.foundation.render.CachedBufferer; + +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.util.Mth; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.AABB; +import net.minecraftforge.fluids.FluidStack; + +public class CastingSpoutRenderer extends SafeBlockEntityRenderer { + + public CastingSpoutRenderer(BlockEntityRendererProvider.Context context) { + } + + static final PartialModel[] BITS = + {TFMGPartialModels.CASTING_SPOUT_CONNECTOR, TFMGPartialModels.CASTING_SPOUT_BOTTOM }; + + @Override + protected void renderSafe(CastingSpoutBlockEntity be, float partialTicks, PoseStack ms, MultiBufferSource buffer, + int light, int overlay) { + + SmartFluidTankBehaviour tank = be.tank1; + if (tank == null) + return; + + TankSegment primaryTank = be.tank1.getPrimaryTank(); + FluidStack fluidStack = primaryTank.getRenderedFluid(); + float level = primaryTank.getFluidLevel() + .getValue(partialTicks); + + if (!fluidStack.isEmpty() && level != 0) { + boolean top = fluidStack.getFluid() + .getFluidType() + .isLighterThanAir(); + + level = Math.max(level, 0.175f); + float min = 2.5f / 16f; + float max = min + (11 / 16f); + float yOffset = (11 / 16f) * level; + + ms.pushPose(); + if (!top) ms.translate(0, yOffset, 0); + else ms.translate(0, max - min, 0); + + FluidRenderer.renderFluidBox(fluidStack, + min, min - yOffset, min, + max, min, max, + buffer, ms, light, false); + + ms.popPose(); + } + + int processingTicks; + if(be.basin==null){ + processingTicks = 0; + }else + processingTicks = be.basin.timer; + + float processingPT = processingTicks - partialTicks; + float processingProgress = 1 - (processingPT - 5) / 10; + processingProgress = Mth.clamp(processingProgress, 0, 1); + float radius = 0; + + if (be.isRunning) { + radius = (float) (Math.pow(((0.3) - 1), 2) - 1); + AABB bb = new AABB(0.5, .5, 0.5, 0.5, -1.2, 0.5).inflate(radius / 32f); + FluidRenderer.renderFluidBox(fluidStack, (float) bb.minX, (float) bb.minY, (float) bb.minZ, + (float) bb.maxX, (float) bb.maxY, (float) bb.maxZ, buffer, ms, light, true); + } + + + ms.pushPose(); + BlockState blockState = be.getBlockState(); + VertexConsumer vb = buffer.getBuffer(RenderType.solid()); + CachedBufferer.partial(TFMGPartialModels.CASTING_SPOUT_BOTTOM, blockState) + .translateY(be.movement.getValue(partialTicks)*2) + .light(light) + .renderInto(ms, vb); + + CachedBufferer.partial(TFMGPartialModels.CASTING_SPOUT_CONNECTOR, blockState) + .translateY(be.movement.getValue(partialTicks)) + .light(light) + .renderInto(ms, vb); + + ms.popPose(); + + } + +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/recipes/casting/CastingRecipe.java b/src/main/java/com/drmangotea/tfmg/recipes/casting/CastingRecipe.java new file mode 100644 index 00000000..b7ddd1ff --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/casting/CastingRecipe.java @@ -0,0 +1,56 @@ +package com.drmangotea.tfmg.recipes.casting; + +import com.drmangotea.tfmg.registry.TFMGRecipeTypes; +import com.simibubi.create.content.processing.recipe.ProcessingRecipe; +import com.simibubi.create.content.processing.recipe.ProcessingRecipeBuilder.ProcessingRecipeParams; +import com.simibubi.create.foundation.fluid.CombinedTankWrapper; +import com.simibubi.create.foundation.fluid.FluidIngredient; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraftforge.fluids.FluidStack; +import net.minecraftforge.items.wrapper.RecipeWrapper; + +public class CastingRecipe extends ProcessingRecipe { + + public CastingRecipe(ProcessingRecipeParams params) { + super(TFMGRecipeTypes.CASTING, params); + } + + @Override + protected int getMaxInputCount() { + return 0; + } + + @Override + protected int getMaxOutputCount() { + return 3; + } + @Override + protected int getMaxFluidOutputCount() { + return 1; + } + + + public boolean matches(CombinedTankWrapper inv, Level worldIn) { + if (inv.getFluidInTank(0).getAmount()==0) + return false; + return fluidIngredients.get(0) + .test(inv.getFluidInTank(0)); + } + public FluidIngredient getInputFluid(){ + return getFluidIngredients().get(0); + } + public ItemStack getIngotResult(){ + return results.get(0).getStack(); + } + public ItemStack getBlockResult(){ + return results.get(1).getStack(); + } + + + @Override + public boolean matches(RecipeWrapper pContainer, Level pLevel) { + return false; + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java index acd18277..6c318c53 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java @@ -10,6 +10,9 @@ import com.drmangotea.tfmg.blocks.deposits.surface_scanner.SurfaceScannerRendere import com.drmangotea.tfmg.blocks.machines.metal_processing.blast_furnace.BlastFurnaceOutputBlockEntity; import com.drmangotea.tfmg.blocks.machines.metal_processing.blast_furnace.BlastFurnaceRenderer; import com.drmangotea.tfmg.blocks.machines.metal_processing.blast_furnace.MoltenMetalBlockEntity; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingBasinBlockEntity; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout.CastingSpoutBlockEntity; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout.CastingSpoutRenderer; import com.drmangotea.tfmg.blocks.machines.metal_processing.coke_oven.CokeOvenBlockEntity; import com.drmangotea.tfmg.blocks.machines.metal_processing.coke_oven.CokeOvenRenderer; import com.drmangotea.tfmg.blocks.machines.oil_processing.distillation.distillation_tower.DistillationControllerBlockEntity; @@ -184,6 +187,17 @@ public class TFMGBlockEntities { .validBlocks(TFMGBlocks.MOLTEN_METAL) .register(); + public static final BlockEntityEntry CASTING_BASIN = REGISTRATE + .blockEntity("casting_basin", CastingBasinBlockEntity::new) + .validBlocks(TFMGBlocks.CASTING_BASIN) + .register(); + + public static final BlockEntityEntry CASTING_SPOUT = REGISTRATE + .blockEntity("casting_spout", CastingSpoutBlockEntity::new) + .renderer(()->CastingSpoutRenderer::new) + .validBlocks(TFMGBlocks.CASTING_SPOUT) + .register(); + public static void register() {} } diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java index c15e2243..489e0602 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java @@ -8,6 +8,8 @@ import com.drmangotea.tfmg.blocks.concrete.formwork.FormWorkGenerator; import com.drmangotea.tfmg.blocks.decoration.doors.TFMGSlidingDoorBlock; import com.drmangotea.tfmg.blocks.deposits.FluidDepositBlock; import com.drmangotea.tfmg.blocks.gadgets.explosives.napalm.NapalmBombBlock; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingBasinBlock; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_spout.CastingSpoutBlock; import com.drmangotea.tfmg.items.CoalCokeBlockItem; import com.drmangotea.tfmg.items.FossilstoneItem; import com.drmangotea.tfmg.blocks.deposits.surface_scanner.SurfaceScannerBlock; @@ -68,7 +70,7 @@ import static com.simibubi.create.foundation.data.CreateRegistrate.connectedText import static com.simibubi.create.foundation.data.ModelGen.customItemModel; import static com.simibubi.create.foundation.data.TagGen.*; - +@SuppressWarnings("removal") public class TFMGBlocks { @@ -376,6 +378,32 @@ public static final BlockEntry STEEL_DISTILLATION_OUTPU .forAllStatesExcept(BlockStateGen.mapToAir(p))) .register(); + //--Casting Basin + public static final BlockEntry CASTING_BASIN = REGISTRATE.block("casting_basin", CastingBasinBlock::new) + .initialProperties(() -> Blocks.IRON_BLOCK) + .properties(p -> p.color(MaterialColor.TERRACOTTA_BLACK)) + .properties(p -> p.requiresCorrectToolForDrops()) + .transform(pickaxeOnly()) + .blockstate((ctx, prov) -> prov.simpleBlock(ctx.getEntry(), AssetLookup.partialBaseModel(ctx, prov))) + .addLayer(() -> RenderType::cutoutMipped) + .item() + .build() + .lang("Casting Basin") + .register(); + + public static final BlockEntry CASTING_SPOUT = REGISTRATE.block("casting_spout", CastingSpoutBlock::new) + .initialProperties(() -> Blocks.IRON_BLOCK) + .properties(p -> p.color(MaterialColor.TERRACOTTA_BLACK)) + .properties(p -> p.requiresCorrectToolForDrops()) + .transform(pickaxeOnly()) + .blockstate((ctx, prov) -> prov.simpleBlock(ctx.getEntry(), AssetLookup.partialBaseModel(ctx, prov))) + .addLayer(() -> RenderType::cutoutMipped) + .item() + .build() + .lang("Casting Spout") + .register(); + + ////////// public static final BlockEntry COKE_OVEN = REGISTRATE.block("coke_oven", CokeOvenBlock::new) .initialProperties(() -> Blocks.BRICKS) @@ -387,6 +415,8 @@ public static final BlockEntry STEEL_DISTILLATION_OUTPU .transform(customItemModel()) .lang("Coke Oven") .register(); + /////// + diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGItems.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGItems.java index 87c83389..c4cce748 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGItems.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGItems.java @@ -3,6 +3,8 @@ package com.drmangotea.tfmg.registry; import com.drmangotea.tfmg.blocks.gadgets.explosives.thermite_grenades.ChemicalColor; import com.drmangotea.tfmg.blocks.gadgets.explosives.thermite_grenades.ThermiteGrenadeItem; import com.drmangotea.tfmg.blocks.gadgets.quad_potato_cannon.QuadPotatoCannonItem; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingBasinBlockEntity; +import com.drmangotea.tfmg.blocks.machines.metal_processing.casting_basin.CastingMoldItem; import com.drmangotea.tfmg.items.CoalCokeItem; import com.drmangotea.tfmg.items.ScrewdriverItem; import com.simibubi.create.foundation.data.AssetLookup; @@ -38,7 +40,9 @@ public class TFMGItems { REGISTRATE.item("quad_potato_cannon", QuadPotatoCannonItem::new) .model(AssetLookup.itemModelWithPartials()) .register(); - + public static final ItemEntry + BLOCK_MOLD = REGISTRATE.item("block_mold", p -> new CastingMoldItem(p, CastingBasinBlockEntity.MoldType.BLOCK)).properties(p -> p.stacksTo(1)).register(), + INGOT_MOLD = REGISTRATE.item("ingot_mold", p -> new CastingMoldItem(p, CastingBasinBlockEntity.MoldType.INGOT)).properties(p -> p.stacksTo(1)).register(); public static final ItemEntry COAL_COKE = REGISTRATE.item("coal_coke", CoalCokeItem::new) .register(); diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java index 8ec95982..dd6cb3ea 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java @@ -19,6 +19,8 @@ public class TFMGPartialModels { public static final PartialModel + CASTING_SPOUT_CONNECTOR = block("casting_spout/connector"), + CASTING_SPOUT_BOTTOM = block("casting_spout/bottom"), COKE_OVEN_DOOR_LEFT = block("coke_oven/door_left"), COKE_OVEN_DOOR_RIGHT = block("coke_oven/door_right"), COKE_OVEN_DOOR_LEFT_TOP = block("coke_oven/door_left_top"), diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java index 6eff2545..0d085411 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java @@ -2,6 +2,7 @@ package com.drmangotea.tfmg.registry; import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.recipes.casting.CastingRecipe; import com.drmangotea.tfmg.recipes.coking.CokingRecipe; import com.drmangotea.tfmg.recipes.distillation.DistillationRecipe; import com.drmangotea.tfmg.recipes.distillation.AdvancedDistillationRecipe; @@ -31,6 +32,7 @@ import java.util.function.Supplier; public enum TFMGRecipeTypes implements IRecipeTypeInfo { +CASTING(CastingRecipe::new), INDUSTRIAL_BLASTING(IndustrialBlastingRecipe::new), COKING(CokingRecipe::new), DISTILLATION(DistillationRecipe::new), diff --git a/src/main/resources/assets/tfmg/models/block/casting_basin/block.json b/src/main/resources/assets/tfmg/models/block/casting_basin/block.json new file mode 100644 index 00000000..e12a8ccb --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/casting_basin/block.json @@ -0,0 +1,58 @@ +{ + "credit": "Made with Blockbench", + "parent": "block/block", + "textures": { + "12": "create:block/basin", + "particle": "create:block/industrial_iron_block" + }, + "elements": [ + { + "name": "Basin", + "from": [0, 2, 0], + "to": [16, 16, 16], + "faces": { + "north": {"uv": [0, 0, 8, 7], "texture": "#12"}, + "east": {"uv": [0, 0, 8, 7], "texture": "#12"}, + "south": {"uv": [0, 0, 8, 7], "texture": "#12"}, + "west": {"uv": [0, 0, 8, 7], "texture": "#12"}, + "up": {"uv": [0, 8, 8, 16], "texture": "#12"}, + "down": {"uv": [0, 8, 8, 16], "texture": "#12"} + } + }, + { + "name": "Basin Interior", + "from": [1.95, 16, 1.95], + "to": [14.05, 2, 14.05], + "faces": { + "north": {"uv": [9, 0, 15, 7], "rotation": 180, "texture": "#12"}, + "east": {"uv": [9, 0, 15, 7], "rotation": 180, "texture": "#12"}, + "south": {"uv": [9, 0, 15, 7], "rotation": 180, "texture": "#12"}, + "west": {"uv": [9, 0, 15, 7], "rotation": 180, "texture": "#12"}, + "up": {"uv": [9, 9, 15, 15], "rotation": 90, "texture": "#12"} + } + }, + { + "name": "Basin Base", + "from": [2, 0, 2], + "to": [14, 2, 14], + "faces": { + "north": {"uv": [1, 7, 7, 8], "texture": "#12"}, + "east": {"uv": [1, 7, 7, 8], "texture": "#12"}, + "south": {"uv": [1, 7, 7, 8], "texture": "#12"}, + "west": {"uv": [1, 7, 7, 8], "texture": "#12"}, + "down": {"uv": [9, 9, 15, 15], "texture": "#12"} + } + } + ], + "groups": [ + { + "name": "Basin", + "origin": [8, 8, 8], + "color": 0, + "children": [] + }, + 0, + 1, + 2 + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/casting_spout/block.json b/src/main/resources/assets/tfmg/models/block/casting_spout/block.json new file mode 100644 index 00000000..c49ac478 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/casting_spout/block.json @@ -0,0 +1,44 @@ +{ + "credit": "Made with Blockbench", + "elements": [ + { + "from": [1, 2, 1], + "to": [15, 14, 15], + "color": 2, + "faces": { + "north": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "east": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "south": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "west": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "up": {"uv": [0, 0, 14, 14], "texture": "#missing"}, + "down": {"uv": [0, 0, 14, 14], "texture": "#missing"} + } + }, + { + "from": [2, 0, 2], + "to": [14, 2, 14], + "color": 7, + "faces": { + "north": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 12, 12], "texture": "#missing"}, + "down": {"uv": [0, 0, 12, 12], "texture": "#missing"} + } + }, + { + "from": [2, 14, 2], + "to": [14, 16, 14], + "color": 7, + "faces": { + "north": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 12, 12], "texture": "#missing"}, + "down": {"uv": [0, 0, 12, 12], "texture": "#missing"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/casting_spout/bottom.json b/src/main/resources/assets/tfmg/models/block/casting_spout/bottom.json new file mode 100644 index 00000000..d10dede4 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/casting_spout/bottom.json @@ -0,0 +1,31 @@ +{ + "credit": "Made with Blockbench", + "elements": [ + { + "from": [6, -5, 6], + "to": [10, -2, 10], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "east": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "south": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "west": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "up": {"uv": [0, 0, 4, 4], "texture": "#missing"}, + "down": {"uv": [0, 0, 4, 4], "texture": "#missing"} + } + }, + { + "from": [5, -7, 5], + "to": [11, -5, 11], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 6, 6], "texture": "#missing"}, + "down": {"uv": [0, 0, 6, 6], "texture": "#missing"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/casting_spout/connector.json b/src/main/resources/assets/tfmg/models/block/casting_spout/connector.json new file mode 100644 index 00000000..3b0e6f17 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/casting_spout/connector.json @@ -0,0 +1,18 @@ +{ + "credit": "Made with Blockbench", + "elements": [ + { + "from": [4, -2, 4], + "to": [12, 0, 12], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 8, 8], "texture": "#missing"}, + "down": {"uv": [0, 0, 8, 8], "texture": "#missing"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/casting_spout/item.json b/src/main/resources/assets/tfmg/models/block/casting_spout/item.json new file mode 100644 index 00000000..4f64b8ea --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/casting_spout/item.json @@ -0,0 +1,83 @@ +{ + "credit": "Made with Blockbench", + "elements": [ + { + "from": [1, 2, 1], + "to": [15, 14, 15], + "color": 2, + "faces": { + "north": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "east": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "south": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "west": {"uv": [0, 0, 14, 12], "texture": "#missing"}, + "up": {"uv": [0, 0, 14, 14], "texture": "#missing"}, + "down": {"uv": [0, 0, 14, 14], "texture": "#missing"} + } + }, + { + "from": [2, 0, 2], + "to": [14, 2, 14], + "color": 7, + "faces": { + "north": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 12, 12], "texture": "#missing"}, + "down": {"uv": [0, 0, 12, 12], "texture": "#missing"} + } + }, + { + "from": [2, 14, 2], + "to": [14, 16, 14], + "color": 7, + "faces": { + "north": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 12, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 12, 12], "texture": "#missing"}, + "down": {"uv": [0, 0, 12, 12], "texture": "#missing"} + } + }, + { + "from": [4, -2, 4], + "to": [12, 0, 12], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 8, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 8, 8], "texture": "#missing"}, + "down": {"uv": [0, 0, 8, 8], "texture": "#missing"} + } + }, + { + "from": [5, -7, 5], + "to": [11, -5, 11], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "east": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "south": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "west": {"uv": [0, 0, 6, 2], "texture": "#missing"}, + "up": {"uv": [0, 0, 6, 6], "texture": "#missing"}, + "down": {"uv": [0, 0, 6, 6], "texture": "#missing"} + } + }, + { + "from": [6, -5, 6], + "to": [10, -2, 10], + "color": 5, + "faces": { + "north": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "east": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "south": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "west": {"uv": [0, 0, 4, 3], "texture": "#missing"}, + "up": {"uv": [0, 0, 4, 4], "texture": "#missing"}, + "down": {"uv": [0, 0, 4, 4], "texture": "#missing"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/textures/item/block_mold.png b/src/main/resources/assets/tfmg/textures/item/block_mold.png new file mode 100644 index 00000000..efdf2708 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/item/block_mold.png differ diff --git a/src/main/resources/assets/tfmg/textures/item/ingot_mold.png b/src/main/resources/assets/tfmg/textures/item/ingot_mold.png new file mode 100644 index 00000000..efdf2708 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/item/ingot_mold.png differ diff --git a/src/main/resources/data/tfmg/recipes/casting/test_caasting.json b/src/main/resources/data/tfmg/recipes/casting/test_caasting.json new file mode 100644 index 00000000..ee034451 --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/casting/test_caasting.json @@ -0,0 +1,22 @@ +{ + "type": "tfmg:casting", + "ingredients": [ + { + "fluid": "tfmg:heavy_oil", + "amount": 1 + } + ], + "processingTime": 300, + "results": [ + { + "count": 1, + "item": "tfmg:steel_ingot" + } + , + { + "count": 1, + "item": "tfmg:steel_block" + } + + ] +} \ No newline at end of file diff --git a/src/main/resources/data/tfmg/recipes/casting/test_casting.json b/src/main/resources/data/tfmg/recipes/casting/test_casting.json new file mode 100644 index 00000000..5b5d03c9 --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/casting/test_casting.json @@ -0,0 +1,22 @@ +{ + "type": "tfmg:casting", + "ingredients": [ + { + "fluid": "tfmg:gasoline", + "amount": 1 + } + ], + "processingTime": 200, + "results": [ + { + "count": 1, + "item": "tfmg:aluminum_ingot" + } + , + { + "count": 1, + "item": "tfmg:aluminum_block" + } + + ] +} \ No newline at end of file