diff --git a/build.gradle b/build.gradle index e709b832..5d039c96 100644 --- a/build.gradle +++ b/build.gradle @@ -114,9 +114,6 @@ repositories { } - - - } dependencies { diff --git a/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e b/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e index 5e494b93..e9fe2ff6 100644 --- a/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e +++ b/src/generated/resources/.cache/9047e4e94996e73e9dfde3738763637fb609e07e @@ -1,2 +1,2 @@ -// 1.19.2 2023-09-22T16:49:10.0101293 Create: The Factory Must Grow's lang merger -7dc07e2f297d06725fb6b2378b917fb81966a70d assets/tfmg/lang/en_us.json +// 1.19.2 2023-09-28T15:00:28.8590663 Create: The Factory Must Grow's lang merger +f07ccd29029a20ee86d4dcf16df9f5711b1728a9 assets/tfmg/lang/en_us.json diff --git a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a index c39478ee..49067c8c 100644 --- a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a +++ b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a @@ -1,4 +1,4 @@ -// 1.19.2 2023-09-22T16:49:10.0141303 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-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)] b7f5146505c40c08cdea7ad01fa99048b7ac5451 assets/tfmg/blockstates/aluminum_block.json 933485fa587fccc649b4cbe8f76f15e590cc8bb1 assets/tfmg/blockstates/bauxite.json 2b53ff8e880d35a42388584cb3ca896c55bfaf95 assets/tfmg/blockstates/bauxite_pillar.json @@ -7,6 +7,7 @@ b7f5146505c40c08cdea7ad01fa99048b7ac5451 assets/tfmg/blockstates/aluminum_block. e13ba2fa789c784e4b7cfec3dd4603e29152387e assets/tfmg/blockstates/cast_iron_distillation_controller.json 61bcb8f09523c05fe8ee07a4b8b71a59e98393fe assets/tfmg/blockstates/cast_iron_distillation_output.json ec94bedd045ade74274ffe009569d65083b9fff5 assets/tfmg/blockstates/coal_coke_block.json +620a4bc51eba9a891e5db9ff0e5b87a4e0843e17 assets/tfmg/blockstates/coke_oven.json c67b91a7fd9f16cd2d7eaa92dd9b945042d58130 assets/tfmg/blockstates/concrete.json dca4728ef33ca9d54fb55d707761c2eeb77c32b1 assets/tfmg/blockstates/cooling_fluid.json 8b6052f05d1b9cd80062de3fb79e36eb0727ecd5 assets/tfmg/blockstates/copper_encased_steel_pipe.json @@ -65,8 +66,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 -fd454201619789195f2c164c19e2f61ab727bfe5 assets/tfmg/lang/en_ud.json -e80d79d10c0e092c3a2b7b8a97d08fb38a6f7e76 assets/tfmg/lang/en_us.json +2c438721675e87e549f147887e3d0604acae4e20 assets/tfmg/lang/en_ud.json +eda6d43bb8bd4174ddbfa181989dce755756e941 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 @@ -191,6 +192,7 @@ da2c28e98d0ddf7166bdf7214c06e81ad8581b90 assets/tfmg/models/item/cast_iron_ingot d45fc5511b4c4027889afd3088cd91ba1d8b0501 assets/tfmg/models/item/coal_coke.json 3789a9d72a7ba5daf8c39cccaa665057e63302c6 assets/tfmg/models/item/coal_coke_block.json cf3c486158a27cbd3a4ef9fdd79dc93f3cc12b45 assets/tfmg/models/item/coal_coke_dust.json +36998ab88f5e75bcb9105baeb1a77030abd9a8bd assets/tfmg/models/item/coke_oven.json 4a843d55647a606fa97bc2daf745a7603406767d assets/tfmg/models/item/concrete.json e8c4e68647a6ced815cfca649c679e709fcc7751 assets/tfmg/models/item/cooling_fluid_bucket.json df4e7fa8f3f60908f58794528a8db60dce7d0135 assets/tfmg/models/item/copper_grenade.json @@ -287,7 +289,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 -b156ae4361196e2464f03fb95a11d5d9e3d03850 data/minecraft/tags/blocks/mineable/pickaxe.json +02cc402fd90edb75d6a0e43851d4eca2912bd0bc 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 @@ -343,6 +345,7 @@ a4b393a2526bd10fa38095ac80769f913f139889 data/tfmg/loot_tables/blocks/aluminum_b 300a96dcae25ba9bc085ee75f066b4ad2590b6e0 data/tfmg/loot_tables/blocks/cast_iron_distillation_controller.json 24517e07383f7a7eb8651f58721cf9f6f49393c0 data/tfmg/loot_tables/blocks/cast_iron_distillation_output.json 5158b18945a39616eef93de8de61dd948fc96f0a data/tfmg/loot_tables/blocks/coal_coke_block.json +6d840276eea351529a8bd24f456869d7d55ac823 data/tfmg/loot_tables/blocks/coke_oven.json d32a75f20ca3f2da6ba69b0a91e295c63f65de92 data/tfmg/loot_tables/blocks/concrete.json 1622328d319fc3c71269b0f9f1aef43a77132f3a data/tfmg/loot_tables/blocks/copper_encased_steel_pipe.json 6874888d31bcadadb4a850b75c1bc780af9de9a2 data/tfmg/loot_tables/blocks/cut_bauxite.json diff --git a/src/generated/resources/assets/tfmg/blockstates/coke_oven.json b/src/generated/resources/assets/tfmg/blockstates/coke_oven.json new file mode 100644 index 00000000..3b0f7617 --- /dev/null +++ b/src/generated/resources/assets/tfmg/blockstates/coke_oven.json @@ -0,0 +1,109 @@ +{ + "variants": { + "controller_type=bottom_off,facing=east": { + "model": "tfmg:block/coke_oven/block_bottom_off", + "y": 270 + }, + "controller_type=bottom_off,facing=north": { + "model": "tfmg:block/coke_oven/block_bottom_off", + "y": 180 + }, + "controller_type=bottom_off,facing=south": { + "model": "tfmg:block/coke_oven/block_bottom_off" + }, + "controller_type=bottom_off,facing=west": { + "model": "tfmg:block/coke_oven/block_bottom_off", + "y": 90 + }, + "controller_type=bottom_on,facing=east": { + "model": "tfmg:block/coke_oven/block_bottom_on", + "y": 270 + }, + "controller_type=bottom_on,facing=north": { + "model": "tfmg:block/coke_oven/block_bottom_on", + "y": 180 + }, + "controller_type=bottom_on,facing=south": { + "model": "tfmg:block/coke_oven/block_bottom_on" + }, + "controller_type=bottom_on,facing=west": { + "model": "tfmg:block/coke_oven/block_bottom_on", + "y": 90 + }, + "controller_type=casual,facing=east": { + "model": "tfmg:block/coke_oven/block_casual", + "y": 270 + }, + "controller_type=casual,facing=north": { + "model": "tfmg:block/coke_oven/block_casual", + "y": 180 + }, + "controller_type=casual,facing=south": { + "model": "tfmg:block/coke_oven/block_casual" + }, + "controller_type=casual,facing=west": { + "model": "tfmg:block/coke_oven/block_casual", + "y": 90 + }, + "controller_type=middle_off,facing=east": { + "model": "tfmg:block/coke_oven/block_middle_off", + "y": 270 + }, + "controller_type=middle_off,facing=north": { + "model": "tfmg:block/coke_oven/block_middle_off", + "y": 180 + }, + "controller_type=middle_off,facing=south": { + "model": "tfmg:block/coke_oven/block_middle_off" + }, + "controller_type=middle_off,facing=west": { + "model": "tfmg:block/coke_oven/block_middle_off", + "y": 90 + }, + "controller_type=middle_on,facing=east": { + "model": "tfmg:block/coke_oven/block_middle_on", + "y": 270 + }, + "controller_type=middle_on,facing=north": { + "model": "tfmg:block/coke_oven/block_middle_on", + "y": 180 + }, + "controller_type=middle_on,facing=south": { + "model": "tfmg:block/coke_oven/block_middle_on" + }, + "controller_type=middle_on,facing=west": { + "model": "tfmg:block/coke_oven/block_middle_on", + "y": 90 + }, + "controller_type=top_off,facing=east": { + "model": "tfmg:block/coke_oven/block_top_off", + "y": 270 + }, + "controller_type=top_off,facing=north": { + "model": "tfmg:block/coke_oven/block_top_off", + "y": 180 + }, + "controller_type=top_off,facing=south": { + "model": "tfmg:block/coke_oven/block_top_off" + }, + "controller_type=top_off,facing=west": { + "model": "tfmg:block/coke_oven/block_top_off", + "y": 90 + }, + "controller_type=top_on,facing=east": { + "model": "tfmg:block/coke_oven/block_top_on", + "y": 270 + }, + "controller_type=top_on,facing=north": { + "model": "tfmg:block/coke_oven/block_top_on", + "y": 180 + }, + "controller_type=top_on,facing=south": { + "model": "tfmg:block/coke_oven/block_top_on" + }, + "controller_type=top_on,facing=west": { + "model": "tfmg:block/coke_oven/block_top_on", + "y": 90 + } + } +} \ 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 0b7b8d25..cb4b4bbc 100644 --- a/src/generated/resources/assets/tfmg/lang/en_ud.json +++ b/src/generated/resources/assets/tfmg/lang/en_ud.json @@ -7,6 +7,7 @@ "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.coal_coke_block": "ǝʞoƆ ןɐoƆ ɟo ʞɔoןᗺ", + "block.tfmg.coke_oven": "uǝʌO ǝʞoƆ", "block.tfmg.concrete": "ǝʇǝɹɔuoƆ", "block.tfmg.cooling_fluid": "pınןℲ buıןooƆ", "block.tfmg.copper_encased_steel_pipe": "ǝdıԀ ןǝǝʇS pǝsɐɔuƎ ɹǝddoƆ", diff --git a/src/generated/resources/assets/tfmg/lang/en_us.json b/src/generated/resources/assets/tfmg/lang/en_us.json index a907ebeb..c5976ec1 100644 --- a/src/generated/resources/assets/tfmg/lang/en_us.json +++ b/src/generated/resources/assets/tfmg/lang/en_us.json @@ -10,6 +10,7 @@ "block.tfmg.cast_iron_distillation_controller": "Cast Iron Distillation Controller", "block.tfmg.cast_iron_distillation_output": "Cast Iron Distillation Output", "block.tfmg.coal_coke_block": "Block of Coal Coke", + "block.tfmg.coke_oven": "Coke Oven", "block.tfmg.concrete": "Concrete", "block.tfmg.cooling_fluid": "Cooling Fluid", "block.tfmg.copper_encased_steel_pipe": "Copper Encased Steel Pipe", @@ -120,9 +121,6 @@ "item.tfmg.thermite_grenade": "Thermite Grenade", "item.tfmg.zinc_grenade": "Zinc Grenade", - - "_": "->------------------------] UI & Messages [------------------------<-", - "itemGroup.tfmg.base": "Create: The Factory Must Grow", "itemGroup.tfmg.building": "Create: TFMG's Building Blocks", @@ -142,7 +140,7 @@ "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 Stats:", + "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", @@ -153,6 +151,59 @@ "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": "%", + + + "_": "->------------------------] UI & Messages [------------------------<-", + + "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.percent_symbol": "%", + "create.goggles.misc.dot_one": ".", + "create.goggles.misc.dot_two": "..", + "create.goggles.misc.dot_three": "...", + "create.goggles.misc.storage_info": "Storage Info:", + "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.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", "_": "Thank you for translating Create: The Factory Must Grow!" diff --git a/src/generated/resources/assets/tfmg/models/item/coke_oven.json b/src/generated/resources/assets/tfmg/models/item/coke_oven.json new file mode 100644 index 00000000..988a1b83 --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/coke_oven.json @@ -0,0 +1,3 @@ +{ + "parent": "tfmg:block/coke_oven/item" +} \ 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 a3d35055..dcb005ab 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,7 @@ "tfmg:fireproof_bricks", "tfmg:fireproof_brick_reinforcement", "tfmg:blast_furnace_output", + "tfmg:coke_oven", "tfmg:steel_block", "tfmg:cast_iron_block", "tfmg:aluminum_block", diff --git a/src/generated/resources/data/tfmg/loot_tables/blocks/coke_oven.json b/src/generated/resources/data/tfmg/loot_tables/blocks/coke_oven.json new file mode 100644 index 00000000..ee845e08 --- /dev/null +++ b/src/generated/resources/data/tfmg/loot_tables/blocks/coke_oven.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "tfmg:coke_oven" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java b/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java index e808a32f..c8a108d0 100644 --- a/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java +++ b/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java @@ -14,7 +14,6 @@ public class CreateTFMGClient { IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus(); TFMGPartialModels.init(); modEventBus.register(this); - } diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java b/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java index ecd5570d..3fc93cd2 100644 --- a/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java +++ b/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java @@ -11,6 +11,7 @@ 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.world.level.block.entity.BlockEntityType; import net.minecraft.world.level.block.state.BlockState; @@ -34,8 +35,7 @@ public class TFMGMachineBlockEntity extends SmartBlockEntity implements IHaveGo public TFMGMachineBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { super(type, pos, state); - tank1.forbidExtraction(); - tank2.forbidInsertion(); + contentsChanged = true; @@ -49,10 +49,9 @@ public class TFMGMachineBlockEntity extends SmartBlockEntity implements IHaveGo .whenFluidUpdates(() -> contentsChanged = true); tank2 = new SmartFluidTankBehaviour(SmartFluidTankBehaviour.OUTPUT, this, 1, 1000, true) - .whenFluidUpdates(() -> contentsChanged = true) - .forbidInsertion(); - behaviours.add(tank1); + .whenFluidUpdates(() -> contentsChanged = true); behaviours.add(tank1); + behaviours.add(tank2); fluidCapability = LazyOptional.of(() -> { LazyOptional inputCap = tank1.getCapability(); @@ -143,4 +142,6 @@ public class TFMGMachineBlockEntity extends SmartBlockEntity implements IHaveGo return true; } + + } diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceOutputBlockEntity.java b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceOutputBlockEntity.java index e01dde62..cea17611 100644 --- a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceOutputBlockEntity.java +++ b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceOutputBlockEntity.java @@ -123,7 +123,6 @@ public class BlastFurnaceOutputBlockEntity extends TFMGMachineBlockEntity implem @Override protected void read(CompoundTag compound, boolean clientPacket) { super.read(compound, clientPacket); - inputInventory.deserializeNBT(compound.getCompound("InputItems")); fuelInventory.deserializeNBT(compound.getCompound("Fuel")); } diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceRenderer.java b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceRenderer.java index 83710ad1..4c6d6209 100644 --- a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceRenderer.java +++ b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/blast_furnace/blast_furnace_output/BlastFurnaceRenderer.java @@ -8,11 +8,14 @@ import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import com.simibubi.create.foundation.blockEntity.renderer.SafeBlockEntityRenderer; import com.simibubi.create.foundation.render.CachedBufferer; +import net.minecraft.client.renderer.LevelRenderer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; import net.minecraft.world.level.block.state.BlockState; +import static net.minecraft.world.level.block.HorizontalDirectionalBlock.FACING; + public class BlastFurnaceRenderer extends SafeBlockEntityRenderer { public BlastFurnaceRenderer(BlockEntityRendererProvider.Context context) {} @@ -27,7 +30,9 @@ public class BlastFurnaceRenderer extends SafeBlockEntityRenderer, IWrenchable { + + public static final EnumProperty CONTROLLER_TYPE = EnumProperty.create("controller_type", ControllerType.class); + + public CokeOvenBlock(Properties p_54120_) { + super(p_54120_); + registerDefaultState(defaultBlockState().setValue(CONTROLLER_TYPE, ControllerType.CASUAL)); + + } + @Override + public InteractionResult onWrenched(BlockState state, UseOnContext context) { + + Level level = context.getLevel(); + BlockPos pos = context.getClickedPos(); + BlockEntity be = level.getBlockEntity(pos); + if(be instanceof CokeOvenBlockEntity) + if(((CokeOvenBlockEntity) be).isValid()) { + ((CokeOvenBlockEntity) be).isController = !((CokeOvenBlockEntity) be).isController; + level.setBlock(pos,state.setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.CASUAL),2); + if(level.getBlockEntity(pos.below())instanceof CokeOvenBlockEntity) + level.setBlock(pos.below(),level.getBlockState(pos.below()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.CASUAL).setValue(FACING,state.getValue(FACING)),2); + if(level.getBlockEntity(pos.above())instanceof CokeOvenBlockEntity) + level.setBlock(pos.above(),level.getBlockState(pos.above()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.CASUAL).setValue(FACING,state.getValue(FACING)),2); + + } + + + return InteractionResult.SUCCESS; + + } + @Override + protected void createBlockStateDefinition(StateDefinition.Builder pBuilder) { + pBuilder.add(FACING,CONTROLLER_TYPE); + super.createBlockStateDefinition(pBuilder); + } + public BlockState getStateForPlacement(BlockPlaceContext p_48781_) { + return this.defaultBlockState().setValue(FACING, p_48781_.getHorizontalDirection().getOpposite()).setValue(CONTROLLER_TYPE,ControllerType.CASUAL); + } + @Override + public Class getBlockEntityClass() { + return CokeOvenBlockEntity.class; + } + + @Override + public BlockEntityType getBlockEntityType() { + return TFMGBlockEntities.COKE_OVEN.get(); + } + + public enum ControllerType implements StringRepresentable { + + CASUAL("casual"), + TOP_OFF("top_off"), + TOP_ON("top_on"), + MIDDLE_OFF("middle_off"), + MIDDLE_ON("middle_on"), + BOTTOM_OFF("bottom_off"), + BOTTOM_ON("bottom_on"); + + private final String name; + + ControllerType(String name) { + this.name = name; + } + + + @Override + public String getSerializedName() { + return this.name; + } + } + + +} diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenBlockEntity.java b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenBlockEntity.java new file mode 100644 index 00000000..785875b6 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenBlockEntity.java @@ -0,0 +1,492 @@ +package com.drmangotea.tfmg.content.machines.metal_processing.coke_oven; + +import com.drmangotea.tfmg.content.machines.TFMGMachineBlockEntity; +import com.drmangotea.tfmg.recipes.coking.CokingRecipe; +import com.drmangotea.tfmg.registry.*; +import com.simibubi.create.content.equipment.wrench.IWrenchable; +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.utility.Lang; +import com.simibubi.create.foundation.utility.animation.LerpedFloat; +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.world.entity.item.ItemEntity; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.AABB; +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.fluids.capability.templates.FluidTank; +import net.minecraftforge.items.CapabilityItemHandler; +import net.minecraftforge.items.IItemHandlerModifiable; +import net.minecraftforge.items.wrapper.CombinedInvWrapper; +import net.minecraftforge.items.wrapper.RecipeWrapper; + +import javax.annotation.Nonnull; +import java.util.List; +import java.util.Optional; + + +import static com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenBlock.CONTROLLER_TYPE; +import static net.minecraft.world.level.block.HorizontalDirectionalBlock.FACING; + +public class CokeOvenBlockEntity extends TFMGMachineBlockEntity implements IWrenchable { + + public boolean isController=false; + + public CokeOvenBlockEntity controller; + + public CokingRecipe lastRecipe; + + int progress = 0; + + public LerpedFloat visualDoorAngle = LerpedFloat.angular(); + public int doorAngle = 0; + + + public int timer = -1; + + public SmartInventory inputInventory; + public LazyOptional itemCapability; + + public final int CARBON_DIOXIDE_PRODUCTION = 9; + + public CokeOvenBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + inputInventory = new SmartInventory(1, this) + .withMaxStackSize(64); + + + itemCapability = LazyOptional.of(() -> new CombinedInvWrapper(inputInventory)); + + tank2.forbidInsertion(); + tank1.forbidInsertion(); + } + + public void tick(){ + super.tick(); + + + if(controller==null){ + inputInventory.forbidInsertion(); + } else { + inputInventory.allowInsertion(); + } + + visualDoorAngle.chase(doorAngle, 0.2f, LerpedFloat.Chaser.EXP); + visualDoorAngle.tickChaser(); + + + + // if(controller != null) + // refreshCapability(); + if(isController){ + controller = this; + } + setControllers(); + + if(controller!=null) + if(!controller.isController) + controller=null; + + if(controller!=null) + if(!(level.getBlockEntity(controller.getBlockPos()) instanceof CokeOvenBlockEntity)) + controller = null; + + + setBlockState(); + + setTimer(); + + if(lastRecipe!=null) { + if(timer == -1){ + progress = 0; + }else { + + progress = 100-(timer/(lastRecipe.getProcessingDuration()/100)); + } + } + + + if(timer>=0&&timer<44){ + doorAngle = 90; + }else doorAngle = 0; + + + + if(timer==0) { + timer=-1; + process(); + } + + ///// + RecipeWrapper inventoryIn = new RecipeWrapper(inputInventory); + if (lastRecipe == null || !lastRecipe.matches(inventoryIn, level)) { + Optional recipe = TFMGRecipeTypes.COKING.find(inventoryIn, level); + if (!recipe.isPresent()) { + timer = -1; + sendData(); + } else { + lastRecipe = recipe.get(); + sendData(); + } + return; + } + + + + + + } + + public void setBlockState(){ + + if(controller == null){ + level.setBlock(getBlockPos(),this.getBlockState().setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.CASUAL),2); + + } + + + if(!this.isController) + return; + + + if(timer==-1) { + level.setBlock(getBlockPos(),this.getBlockState().setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.MIDDLE_OFF),2); + if(level.getBlockEntity(getBlockPos().below())instanceof CokeOvenBlockEntity) + level.setBlock(getBlockPos().below(),level.getBlockState(getBlockPos().below()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.BOTTOM_OFF).setValue(FACING,this.getBlockState().getValue(FACING)),2); + if(level.getBlockEntity(getBlockPos().above())instanceof CokeOvenBlockEntity) + level.setBlock(getBlockPos().above(),level.getBlockState(getBlockPos().above()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.TOP_OFF).setValue(FACING,this.getBlockState().getValue(FACING)),2); + }else { + level.setBlock(getBlockPos(),this.getBlockState().setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.MIDDLE_ON),2); + if(level.getBlockEntity(getBlockPos().below())instanceof CokeOvenBlockEntity) + level.setBlock(getBlockPos().below(),level.getBlockState(getBlockPos().below()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.BOTTOM_ON).setValue(FACING,this.getBlockState().getValue(FACING)),2); + if(level.getBlockEntity(getBlockPos().above())instanceof CokeOvenBlockEntity) + level.setBlock(getBlockPos().above(),level.getBlockState(getBlockPos().above()).setValue(CONTROLLER_TYPE, CokeOvenBlock.ControllerType.TOP_ON).setValue(FACING,this.getBlockState().getValue(FACING)),2); + } + + + + + + + + } + + private void setTimer() { + + + if(lastRecipe!=null + &&isController + &&timer==-1 + &&inputInventory.getItem(0).getCount()>=20&& + (tank2.getPrimaryHandler().getFluidAmount()+CARBON_DIOXIDE_PRODUCTION)<=tank2.getPrimaryHandler().getCapacity()&& + (tank1.getPrimaryHandler().getFluidAmount()+lastRecipe.getFluidResults().get(0).getAmount())<=tank1.getPrimaryHandler().getCapacity() + ){ + timer = lastRecipe.getProcessingDuration(); + inputInventory.setItem(0,new ItemStack(inputInventory.getItem(0).getItem(),inputInventory.getItem(0).getCount()-20)); + + } + // if(lastRecipe != null) + // if((tank1.getPrimaryHandler().getFluidAmount()+lastRecipe.getFluidResults().get(0).getAmount())>tank1.getPrimaryHandler().getCapacity()) + // timer = -1; + // if(lastRecipe != null) + // if((tank2.getPrimaryHandler().getFluidAmount()+CARBON_DIOXIDE_PRODUCTION)>tank2.getPrimaryHandler().getCapacity()) + // timer = -1; + + + if(lastRecipe!=null + &&timer>0 + &&isController&& + (tank2.getPrimaryHandler().getFluidAmount()+CARBON_DIOXIDE_PRODUCTION)<=tank2.getPrimaryHandler().getCapacity()&& + (tank1.getPrimaryHandler().getFluidAmount()+lastRecipe.getFluidResults().get(0).getAmount())<=tank1.getPrimaryHandler().getCapacity() + ) { + timer--; + tank1.getPrimaryHandler().setFluid(new FluidStack(lastRecipe.getFluidResults().get(0), tank1.getPrimaryHandler().getFluidAmount()+lastRecipe.getFluidResults().get(0).getAmount())); + tank2.getPrimaryHandler().setFluid(new FluidStack(TFMGFluids.CARBON_DIOXIDE.getSource(),tank2.getPrimaryHandler().getFluidAmount()+CARBON_DIOXIDE_PRODUCTION)); + } + + } + + public void process(){ + + + if(level.isClientSide) + return; + if(!isController) + return; + RecipeWrapper inventoryIn = new RecipeWrapper(inputInventory); + if (lastRecipe == null || !lastRecipe.matches(inventoryIn, level)) { + Optional recipe = TFMGRecipeTypes.COKING.find(inventoryIn, level); + if (!recipe.isPresent()) + return; + lastRecipe = recipe.get(); + } + BlockPos toSpawn = getBlockPos().below().relative(this.getBlockState().getValue(FACING)); + // + ItemEntity itemToSpawn = new ItemEntity(level,toSpawn.getX()+0.5f,toSpawn.getY()+0.5f,toSpawn.getZ()+0.5f, lastRecipe.getResultItem().copy()); + level.addFreshEntity(itemToSpawn); + + + + } + + @Override + protected AABB createRenderBoundingBox() { + return super.createRenderBoundingBox().expandTowards(0, -2, 0).expandTowards(0, 2, 0); + } + + private void refreshCapability() { + + if(this.controller ==null) { + + + return; + } + + + LazyOptional oldFluidCapability = fluidCapability; + LazyOptional oldItemCapability = itemCapability; + + + + if(controller.tank1==null) + return; + if(controller.tank2==null) + return; + if(controller.inputInventory==null) + return; + fluidCapability = LazyOptional.of(() -> new CombinedTankWrapper(controller.tank1.getPrimaryHandler(), controller.tank2.getPrimaryHandler())); + itemCapability = LazyOptional.of(() -> new CombinedInvWrapper(controller.inputInventory)); + oldFluidCapability.invalidate(); + oldItemCapability.invalidate(); + } + public void setControllers(){ + if(!isValid()) + return; + if(!isController) + return; + + Direction facing = this.getBlockState().getValue(FACING); + + BlockPos checkedPos=this.getBlockPos().above(); + + + for(int i = 0; i<3;i++){ + for(int y = 0; y<3;y++){ + + + + CokeOvenBlockEntity checkedBE = (CokeOvenBlockEntity) level.getBlockEntity(checkedPos); + checkedBE.controller = this; + + checkedPos = checkedPos.below(); + } + + checkedPos = checkedPos.above(3); + checkedPos = checkedPos.relative(facing.getOpposite()); + } + + } + + public boolean isValid(){ + Direction facing = this.getBlockState().getValue(FACING); + + BlockPos checkedPos=this.getBlockPos().above(); + + + for(int i = 0; i<3;i++){ + for(int y = 0; y<3;y++){ + + if(checkedPos == this.getBlockPos()){ + if(!isCokeOvenBlock(checkedPos,true)) { + isController = false; + return false; + } + }else + + if(!isCokeOvenBlock(checkedPos)) { + isController=false; + return false; + } + + if(occupiedByOtherController(checkedPos)) { + isController = false; + return false; + } + + + + checkedPos = checkedPos.below(); + } + + checkedPos = checkedPos.above(3); + checkedPos = checkedPos.relative(facing.getOpposite()); + } + return true ; + } + + public boolean isCokeOvenBlock(BlockPos pos){return isCokeOvenBlock(pos,false);} + public boolean isCokeOvenBlock(BlockPos pos, boolean controllerSensitive){ + if(controllerSensitive) + if(level.getBlockState(pos).is(TFMGBlocks.COKE_OVEN.get())) + if(isController) + return false; + + return level.getBlockState(pos).is(TFMGBlocks.COKE_OVEN.get()); + } + public boolean occupiedByOtherController(BlockPos pos){ + + if(level.getBlockEntity(pos).getBlockState().is(TFMGBlocks.COKE_OVEN.get())) + if(((CokeOvenBlockEntity)level.getBlockEntity(pos)).controller == null||((CokeOvenBlockEntity)level.getBlockEntity(pos)).controller == this) + // if(((CokeOvenBlockEntity)level.getBlockEntity(pos)).controller != this) + return false; + + return true; + } + @Override + public boolean addToGoggleTooltip(List tooltip, boolean isPlayerSneaking) { + //if(controller !=null) + // Lang.translate("goggles.surface_scanner.distance",controller.getBlockPos().getX()) + // .style(ChatFormatting.DARK_BLUE) + // .forGoggles(tooltip,1); + //if(controller !=null) + // Lang.translate("goggles.surface_scanner.distance",controller.getBlockPos().getY()) + // .style(ChatFormatting.DARK_BLUE) + // .forGoggles(tooltip,1); + //if(controller !=null) + // Lang.translate("goggles.surface_scanner.distance",controller.getBlockPos().getZ()) + // .style(ChatFormatting.DARK_BLUE) + // .forGoggles(tooltip,1); +// + //if(controller==null){ + // Lang.translate("aaaaaaaaaaaaaaaaaaaaaaaaaaa") + // .style(ChatFormatting.DARK_RED) + // .forGoggles(tooltip,1); +// + + // return true; + // } + + if(controller.getBlockPos() == getBlockPos()&&!isValid()){ + Lang.translate("goggles.coke_oven.invalid") + .style(ChatFormatting.DARK_RED) + .forGoggles(tooltip,1); + + + return true; + } + + + + if(!isController) + return false; + + + + + if(lastRecipe != null) + if((tank1.getPrimaryHandler().getFluidAmount()+lastRecipe.getFluidResults().get(0).getAmount())>tank1.getPrimaryHandler().getCapacity() + &&(tank2.getPrimaryHandler().getFluidAmount()+CARBON_DIOXIDE_PRODUCTION)>tank2.getPrimaryHandler().getCapacity()) { + Lang.translate("goggles.coke_oven.tank_full") + .style(ChatFormatting.DARK_RED) + .forGoggles(tooltip,1); + return true; + } + + + + Lang.translate("goggles.coke_oven.status") + .style(ChatFormatting.GRAY) + .forGoggles(tooltip,1); + + // + + Lang.translate("goggles.coke_oven.progress", progress) + .add(Lang.translate("goggles.misc.percent_symbol")) + .style(ChatFormatting.DARK_PURPLE) + .forGoggles(tooltip,1); + + + // + Lang.translate("goggles.misc.storage_info") + .style(ChatFormatting.GRAY) + .forGoggles(tooltip,1); + + + + // Lang.translate("goggles.coke_oven.fluid_amount_output",tank1.getPrimaryHandler().getCapacity()) + // .style(ChatFormatting.DARK_AQUA) + // .forGoggles(tooltip,1); + // Lang.translate("goggles.coke_oven.fluid_amount_exhaust",tank2.getPrimaryHandler().getCapacity()) + // .style(ChatFormatting.DARK_AQUA) + // .forGoggles(tooltip,1); + Lang.translate("goggles.coke_oven.item_count",inputInventory.getItem(0).getCount()) + .style(ChatFormatting.GOLD) + .forGoggles(tooltip,1); + + + + + return true; + + } + + @Override + protected void read(CompoundTag compound, boolean clientPacket) { + super.read(compound, clientPacket); + + inputInventory.deserializeNBT(compound.getCompound("InputItems")); + + isController = compound.getBoolean("Is Controller"); + + timer = compound.getInt("Timer"); + + + } + + @Override + public void write(CompoundTag compound, boolean clientPacket) { + super.write(compound, clientPacket); + + compound.put("InputItems", inputInventory.serializeNBT()); + compound.putBoolean("Is Controller",isController); + compound.putInt("Timer", timer); + + + + } + + @Override + public void invalidate() { + super.invalidate(); + itemCapability.invalidate(); + } + @Nonnull + @Override + @SuppressWarnings("'net.minecraftforge.items.CapabilityItemHandler' is deprecated and marked for removal ") + public LazyOptional getCapability(@Nonnull Capability cap, Direction side) { + if(controller!=null) + refreshCapability(); + if (cap == CapabilityItemHandler.ITEM_HANDLER_CAPABILITY) + return itemCapability.cast(); + if (cap == CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY) + return fluidCapability.cast(); + return super.getCapability(cap, side); + } + + + + @Override + public void addBehaviours(List behaviours) { + super.addBehaviours(behaviours); + } +} diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenGenerator.java b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenGenerator.java new file mode 100644 index 00000000..8b73ad07 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenGenerator.java @@ -0,0 +1,50 @@ +package com.drmangotea.tfmg.content.machines.metal_processing.coke_oven; + +import com.drmangotea.tfmg.CreateTFMG; +import com.simibubi.create.content.processing.basin.BasinBlock; +import com.simibubi.create.content.redstone.thresholdSwitch.ThresholdSwitchBlock; +import com.simibubi.create.foundation.data.AssetLookup; +import com.simibubi.create.foundation.data.SpecialBlockStateGen; +import com.simibubi.create.foundation.utility.Lang; +import com.tterrag.registrate.providers.DataGenContext; +import com.tterrag.registrate.providers.RegistrateBlockstateProvider; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraftforge.client.model.generators.ModelFile; + +import java.util.function.Function; + +import static com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenBlock.CONTROLLER_TYPE; +import static com.simibubi.create.foundation.data.AssetLookup.partialBaseModel; + +public class CokeOvenGenerator extends SpecialBlockStateGen { + @Override + protected int getXRotation(BlockState state) { + return 0; + } + + @Override + protected int getYRotation(BlockState state) { + return horizontalAngle(state.getValue(CokeOvenBlock.FACING)); + } + + + + + + + + @Override + public ModelFile getModel(DataGenContext ctx, RegistrateBlockstateProvider prov, + BlockState state) { + + String path = "block/coke_oven/block_" + + state.getValue(CONTROLLER_TYPE).getSerializedName() + ; + + return prov.models() + .getExistingFile(CreateTFMG.asResource(path)); + + } +} diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenRenderer.java b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenRenderer.java new file mode 100644 index 00000000..22925b38 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/machines/metal_processing/coke_oven/CokeOvenRenderer.java @@ -0,0 +1,239 @@ +package com.drmangotea.tfmg.content.machines.metal_processing.coke_oven; + + + +import com.drmangotea.tfmg.registry.TFMGPartialModels; +import com.jozufozu.flywheel.util.transform.TransformStack; +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.simibubi.create.content.contraptions.elevator.ElevatorPulleyBlockEntity; +import com.simibubi.create.foundation.blockEntity.renderer.SafeBlockEntityRenderer; +import com.simibubi.create.foundation.render.CachedBufferer; +import net.minecraft.client.renderer.LevelRenderer; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.core.Direction; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.Vec3; + +import static net.minecraft.world.level.block.HorizontalDirectionalBlock.FACING; + +public class CokeOvenRenderer extends SafeBlockEntityRenderer { + + public CokeOvenRenderer(BlockEntityRendererProvider.Context context) {} + + @Override + protected void renderSafe(CokeOvenBlockEntity be, float partialTicks, PoseStack ms, MultiBufferSource buffer, + int light, int overlay) { + + + + BlockState blockState = be.getBlockState(); + VertexConsumer vb = buffer.getBuffer(RenderType.solid()); + ms.pushPose(); + TransformStack msr = TransformStack.cast(ms); + msr.translate(1 / 2f, 0.5, 1 / 2f); + int lightInFront = Math.max( + LevelRenderer.getLightColor(be.getLevel(), be.getBlockPos().relative(be.getBlockState().getValue(FACING))), + Math.max( + LevelRenderer.getLightColor(be.getLevel(), be.getBlockPos().below().relative(be.getBlockState().getValue(FACING))), + LevelRenderer.getLightColor(be.getLevel(), be.getBlockPos().above().relative(be.getBlockState().getValue(FACING))) + ) + ) + ; + if(be.isController) { + + // CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT, blockState) + // .centre() + // .translate(-1,-1,-1) + // .rotateY(-be.visualDoorAngle.getValue()) + // .light(light) + // .renderInto(ms, vb); + // CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT_TOP, blockState) + // .centre() + // .translate(-1,0,-1) + // .rotateY(-be.visualDoorAngle.getValue()) + // .light(light) + // .renderInto(ms, vb); + + + if(be.getBlockState().getValue(FACING)== Direction.SOUTH) { + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT, blockState) + .centre() + .rotateY(be.visualDoorAngle.getValue()) + .translate(-1, -2, -1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT_TOP, blockState) + .centre() + .rotateY(be.visualDoorAngle.getValue()) + .translate(-1, -1, -1) + .light(lightInFront) + .renderInto(ms, vb); + + + + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT, blockState) + .centre() + .translateX(-1) + .rotateY(-be.visualDoorAngle.getValue()) + .translate(0, -2, -1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT_TOP, blockState) + .centre() + .translateX(-1) + .rotateY(-be.visualDoorAngle.getValue()) + .translate(0, -1, -1) + .light(lightInFront) + .renderInto(ms, vb); + + + } + if(be.getBlockState().getValue(FACING)== Direction.NORTH) { + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT, blockState) + .centre() + .translateZ(-1.01) + .rotateY(-be.visualDoorAngle.getValue()) + .translate(-1, -2, -1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT_TOP, blockState) + .centre() + .translateZ(-1.01) + .rotateY(-be.visualDoorAngle.getValue()) + .translate(-1, -1, -1) + .light(lightInFront) + .renderInto(ms, vb); + + + + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT, blockState) + .centre() + .translateZ(-1.01) + .translateX(-1) + .rotateY(be.visualDoorAngle.getValue()) + .translate(0, -2, -1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT_TOP, blockState) + .centre() + .translateZ(-1.01) + .translateX(-1) + .rotateY(be.visualDoorAngle.getValue()) + .translate(0, -1, -1) + .light(lightInFront) + .renderInto(ms, vb); + + + } + if(be.getBlockState().getValue(FACING)== Direction.WEST) { + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT, blockState) + .centre() + .translateX(-1) + .translateZ(-1) + .translateY(-2) + .rotateY(-be.visualDoorAngle.getValue()+90) + .translateZ(-1.01) + .translateX(-1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT_TOP, blockState) + .centre() + .translateX(-1) + .translateY(-1) + .translateZ(-1) + .rotateY(-be.visualDoorAngle.getValue()+90) + .translateZ(-1.01) + .translateX(-1) + .light(lightInFront) + .renderInto(ms, vb); + + + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT, blockState) + .centre() + .translateX(-1) + .translateY(-2) + .rotateY(be.visualDoorAngle.getValue()+90) + .translateZ(-1.01) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT_TOP, blockState) + .centre() + .translateX(-1) + .translateY(-1) + .rotateY(be.visualDoorAngle.getValue()+90) + .translateZ(-1.01) + .light(lightInFront) + .renderInto(ms, vb); + + + + } + if(be.getBlockState().getValue(FACING)== Direction.EAST) { + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT, blockState) + .centre() + //.translateX(-1) + .translateZ(-1) + .translateY(-2) + .rotateY(be.visualDoorAngle.getValue()+90) + .translateZ(-0.99) + .translateX(-1) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_RIGHT_TOP, blockState) + .centre() + //.translateX(-1) + .translateY(-1) + .translateZ(-1) + .rotateY(be.visualDoorAngle.getValue()+90) + .translateZ(-0.99) + .translateX(-1) + .light(lightInFront) + .renderInto(ms, vb); + + + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT, blockState) + .centre() + //.translateX(-1) + .translateY(-2) + .rotateY(-be.visualDoorAngle.getValue()+90) + .translateZ(-0.99) + .light(lightInFront) + .renderInto(ms, vb); + CachedBufferer.partial(TFMGPartialModels.COKE_OVEN_DOOR_LEFT_TOP, blockState) + .centre() + // .translateX(-1) + .translateY(-1) + .rotateY(-be.visualDoorAngle.getValue()+90) + .translateZ(-0.99) + .light(lightInFront) + .renderInto(ms, vb); + + + + } + + + + + + + } + + + + ms.popPose(); + + } + @Override + public int getViewDistance() { + return 128; + } + + + + +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/recipes/coking/CokingRecipe.java b/src/main/java/com/drmangotea/tfmg/recipes/coking/CokingRecipe.java new file mode 100644 index 00000000..15cc7f49 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/coking/CokingRecipe.java @@ -0,0 +1,40 @@ +package com.drmangotea.tfmg.recipes.coking; + +import com.drmangotea.tfmg.registry.TFMGRecipeTypes; +import com.simibubi.create.AllRecipeTypes; +import com.simibubi.create.content.processing.recipe.ProcessingRecipe; +import com.simibubi.create.content.processing.recipe.ProcessingRecipeBuilder.ProcessingRecipeParams; +import com.simibubi.create.foundation.recipe.IRecipeTypeInfo; +import net.minecraft.world.level.Level; +import net.minecraftforge.items.wrapper.RecipeWrapper; + +public class CokingRecipe extends ProcessingRecipe { + + public CokingRecipe(ProcessingRecipeParams params) { + super(TFMGRecipeTypes.COKING, params); + } + + @Override + protected int getMaxInputCount() { + return 1; + } + + @Override + protected int getMaxOutputCount() { + return 1; + } + @Override + protected int getMaxFluidOutputCount() { + return 1; + } + + + @Override + public boolean matches(RecipeWrapper inv, Level worldIn) { + if (inv.isEmpty()) + return false; + return ingredients.get(0) + .test(inv.getItem(0)); + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/industrial_blasting/IndustrialBlastingRecipe.java b/src/main/java/com/drmangotea/tfmg/recipes/industrial_blasting/IndustrialBlastingRecipe.java new file mode 100644 index 00000000..55f81150 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/industrial_blasting/IndustrialBlastingRecipe.java @@ -0,0 +1,38 @@ +package com.drmangotea.tfmg.recipes.industrial_blasting; + +import com.drmangotea.tfmg.registry.TFMGRecipeTypes; +import com.simibubi.create.content.processing.recipe.ProcessingRecipe; +import com.simibubi.create.content.processing.recipe.ProcessingRecipeBuilder.ProcessingRecipeParams; +import net.minecraft.world.level.Level; +import net.minecraftforge.items.wrapper.RecipeWrapper; + +public class IndustrialBlastingRecipe extends ProcessingRecipe { + + public IndustrialBlastingRecipe(ProcessingRecipeParams params) { + super(TFMGRecipeTypes.INDUSTRIAL_BLASTING, params); + } + + @Override + protected int getMaxInputCount() { + return 1; + } + + @Override + protected int getMaxOutputCount() { + return 0; + } + @Override + protected int getMaxFluidOutputCount() { + return 2; + } + + + @Override + public boolean matches(RecipeWrapper inv, Level worldIn) { + if (inv.isEmpty()) + return false; + return ingredients.get(0) + .test(inv.getItem(0)); + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/CokingCategory.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/CokingCategory.java new file mode 100644 index 00000000..d89ca36e --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/CokingCategory.java @@ -0,0 +1,78 @@ +package com.drmangotea.tfmg.recipes.jei; + + + +import com.drmangotea.tfmg.recipes.coking.CokingRecipe; +import com.drmangotea.tfmg.recipes.jei.machines.CokeOven; +import com.drmangotea.tfmg.recipes.jei.machines.Distillery; +import com.drmangotea.tfmg.registry.TFMGFluids; +import com.mojang.blaze3d.vertex.PoseStack; +import com.simibubi.create.compat.jei.category.CreateRecipeCategory; +import com.simibubi.create.foundation.gui.AllGuiTextures; +import mezz.jei.api.forge.ForgeTypes; +import mezz.jei.api.gui.builder.IRecipeLayoutBuilder; +import mezz.jei.api.gui.ingredient.IRecipeSlotsView; +import mezz.jei.api.recipe.IFocusGroup; +import mezz.jei.api.recipe.RecipeIngredientRole; +import net.minecraft.world.item.ItemStack; +import net.minecraftforge.fluids.FluidStack; + +import javax.annotation.ParametersAreNonnullByDefault; + +@ParametersAreNonnullByDefault +public class CokingCategory extends CreateRecipeCategory { + + private final CokeOven cokeOven = new CokeOven(); + + public CokingCategory(Info info) { + super(info); + } + + + + + @Override + public void setRecipe(IRecipeLayoutBuilder builder, CokingRecipe recipe, IFocusGroup focuses) { + + + builder + .addSlot(RecipeIngredientRole.INPUT, 1, 13) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredients(recipe.getIngredients().get(0)); + + builder + .addSlot(RecipeIngredientRole.OUTPUT, 121, 90) + .setBackground(getRenderedSlot(), -1, -1) + .addItemStack(recipe.getResultItem()); + + //fluid + + builder + .addSlot(RecipeIngredientRole.OUTPUT,160, 46) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredient(ForgeTypes.FLUID_STACK, withImprovedVisibility(new FluidStack(TFMGFluids.CARBON_DIOXIDE.get(),5000))) + .addTooltipCallback(addFluidTooltip(5000)); + + builder + .addSlot(RecipeIngredientRole.OUTPUT,160, 22) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredient(ForgeTypes.FLUID_STACK, withImprovedVisibility(recipe.getFluidResults().get(0))) + .addTooltipCallback(addFluidTooltip(recipe.getFluidResults().get(0).getAmount())); + + } + + @Override + public void draw(CokingRecipe recipe, IRecipeSlotsView iRecipeSlotsView, PoseStack matrixStack, double mouseX, double mouseY) { + cokeOven + .draw(matrixStack, 65, 50); + AllGuiTextures.JEI_ARROW.render(matrixStack, 20, 15); + + + AllGuiTextures.JEI_ARROW.render(matrixStack, 115, 25); + AllGuiTextures.JEI_ARROW.render(matrixStack, 115, 50); + + AllGuiTextures.JEI_DOWN_ARROW.render(matrixStack, 115, 73); + + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/IndustrialBlastingCategory.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/IndustrialBlastingCategory.java new file mode 100644 index 00000000..fafe9388 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/IndustrialBlastingCategory.java @@ -0,0 +1,76 @@ +package com.drmangotea.tfmg.recipes.jei; + + + +import com.drmangotea.tfmg.recipes.industrial_blasting.IndustrialBlastingRecipe; +import com.drmangotea.tfmg.recipes.jei.machines.BlastFurnace; +import com.drmangotea.tfmg.registry.TFMGFluids; +import com.drmangotea.tfmg.registry.TFMGItems; +import com.mojang.blaze3d.vertex.PoseStack; +import com.simibubi.create.compat.jei.category.CreateRecipeCategory; +import com.simibubi.create.foundation.gui.AllGuiTextures; +import mezz.jei.api.forge.ForgeTypes; +import mezz.jei.api.gui.builder.IRecipeLayoutBuilder; +import mezz.jei.api.gui.ingredient.IRecipeSlotsView; +import mezz.jei.api.recipe.IFocusGroup; +import mezz.jei.api.recipe.RecipeIngredientRole; +import net.minecraft.world.item.ItemStack; +import net.minecraftforge.fluids.FluidStack; + +import javax.annotation.ParametersAreNonnullByDefault; + +@ParametersAreNonnullByDefault +public class IndustrialBlastingCategory extends CreateRecipeCategory { + + private final BlastFurnace blastFurnace = new BlastFurnace(); + + public IndustrialBlastingCategory(Info info) { + super(info); + } + + + + + @Override + public void setRecipe(IRecipeLayoutBuilder builder, IndustrialBlastingRecipe recipe, IFocusGroup focuses) { + + + builder + .addSlot(RecipeIngredientRole.INPUT, 25, 13) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredients(recipe.getIngredients().get(0)); + + builder + .addSlot(RecipeIngredientRole.INPUT, 5, 13) + .setBackground(getRenderedSlot(), -1, -1) + .addItemStack(new ItemStack(TFMGItems.COAL_COKE_DUST.get(),2)); + + //fluid + + builder + .addSlot(RecipeIngredientRole.OUTPUT,140, 117) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredient(ForgeTypes.FLUID_STACK, withImprovedVisibility(recipe.getFluidResults().get(0))) + .addTooltipCallback(addFluidTooltip(recipe.getFluidResults().get(0).getAmount())); + + builder + .addSlot(RecipeIngredientRole.OUTPUT,160, 117) + .setBackground(getRenderedSlot(), -1, -1) + .addIngredient(ForgeTypes.FLUID_STACK, withImprovedVisibility(recipe.getFluidResults().get(1))) + .addTooltipCallback(addFluidTooltip(recipe.getFluidResults().get(1).getAmount())); + + } + + @Override + public void draw(IndustrialBlastingRecipe recipe, IRecipeSlotsView iRecipeSlotsView, PoseStack matrixStack, double mouseX, double mouseY) { + blastFurnace + .draw(matrixStack, 50, 135); + + + AllGuiTextures.JEI_ARROW.render(matrixStack, 96, 121); + + AllGuiTextures.JEI_DOWN_ARROW.render(matrixStack, 45, 15); + + } + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/TFMGJei.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/TFMGJei.java index ffa336f7..4d2e6101 100644 --- a/src/main/java/com/drmangotea/tfmg/recipes/jei/TFMGJei.java +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/TFMGJei.java @@ -1,8 +1,10 @@ package com.drmangotea.tfmg.recipes.jei; +import com.drmangotea.tfmg.recipes.coking.CokingRecipe; import com.drmangotea.tfmg.recipes.distillation.DistillationRecipe; import com.drmangotea.tfmg.recipes.distillation.AdvancedDistillationRecipe; +import com.drmangotea.tfmg.recipes.industrial_blasting.IndustrialBlastingRecipe; import com.drmangotea.tfmg.registry.TFMGBlocks; import com.drmangotea.tfmg.registry.TFMGFluids; import com.drmangotea.tfmg.registry.TFMGRecipeTypes; @@ -70,7 +72,21 @@ public class TFMGJei implements IModPlugin { .catalyst(TFMGBlocks.STEEL_DISTILLATION_OUTPUT::get) .itemIcon(TFMGBlocks.STEEL_DISTILLATION_CONTROLLER.get()) .emptyBackground(177, 150) - .build("advanced_distillation", AdvancedDistillationCategory::new) + .build("advanced_distillation", AdvancedDistillationCategory::new), + + coking = builder(CokingRecipe.class) + .addTypedRecipes(TFMGRecipeTypes.COKING) + .catalyst(TFMGBlocks.COKE_OVEN::get) + .emptyBackground(177, 123) + .build("coking", CokingCategory::new), + + industrial_blasting = builder(IndustrialBlastingRecipe.class) + .addTypedRecipes(TFMGRecipeTypes.INDUSTRIAL_BLASTING) + .catalyst(TFMGBlocks.BLAST_FURNACE_OUTPUT::get) + .catalyst(TFMGBlocks.FIREPROOF_BRICKS::get) + .itemIcon(TFMGBlocks.BLAST_FURNACE_OUTPUT.get()) + .emptyBackground(177, 150) + .build("industrial_blasting", IndustrialBlastingCategory::new) ; diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/BlastFurnace.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/BlastFurnace.java new file mode 100644 index 00000000..36ef8bac --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/BlastFurnace.java @@ -0,0 +1,87 @@ +package com.drmangotea.tfmg.recipes.jei.machines; + + +import com.drmangotea.tfmg.registry.TFMGBlocks; +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.math.Vector3f; +import com.simibubi.create.compat.jei.category.animations.AnimatedKinetics; +import com.simibubi.create.content.processing.burner.BlazeBurnerBlock; +import net.minecraft.world.level.block.state.properties.WallSide; + +import static net.minecraft.world.level.block.WallBlock.*; + +public class BlastFurnace extends AnimatedKinetics { + + + + public BlastFurnace() {} + + @Override + public void draw(PoseStack matrixStack, int xOffset, int yOffset) { + matrixStack.pushPose(); + matrixStack.translate(xOffset, yOffset, 200); + matrixStack.mulPose(Vector3f.XP.rotationDegrees(-15.5f)); + matrixStack.mulPose(Vector3f.YP.rotationDegrees(22.5f)); + int scale = 23; + BlazeBurnerBlock.HeatLevel heatLevel = BlazeBurnerBlock.HeatLevel.SMOULDERING; + + + blockElement(TFMGBlocks.BLAST_FURNACE_OUTPUT.getDefaultState()) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICKS.getDefaultState()) + .atLocal(0,0,-1) + .scale(scale) + .render(matrixStack); + + for(int i = 0; i<4;i++) { + if(i !=0) + blockElement(TFMGBlocks.FIREPROOF_BRICKS.getDefaultState()) + .atLocal(0, -i, 0) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICKS.getDefaultState()) + .atLocal(0, -i, -2) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICKS.getDefaultState()) + .atLocal(-1, -i, -1) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICKS.getDefaultState()) + .atLocal(1, -i, -1) + .scale(scale) + .render(matrixStack); + + if(i!=3){ + + blockElement(TFMGBlocks.FIREPROOF_BRICK_REINFORCEMENT.getDefaultState().setValue(NORTH_WALL, WallSide.TALL).setValue(WEST_WALL, WallSide.TALL)) + .atLocal(1, -i, 0) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICK_REINFORCEMENT.getDefaultState().setValue(SOUTH_WALL, WallSide.TALL).setValue(WEST_WALL, WallSide.TALL)) + .atLocal(1, -i, -2) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICK_REINFORCEMENT.getDefaultState().setValue(NORTH_WALL, WallSide.TALL).setValue(EAST_WALL, WallSide.TALL)) + .atLocal(-1, -i, 0) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.FIREPROOF_BRICK_REINFORCEMENT.getDefaultState().setValue(SOUTH_WALL, WallSide.TALL).setValue(EAST_WALL, WallSide.TALL)) + .atLocal(-1, -i, -2) + .scale(scale) + .render(matrixStack); + + } + + } + + + matrixStack.scale(scale, -scale, scale); + matrixStack.translate(0, -1.8, 0); + matrixStack.popPose(); + } + + + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/CokeOven.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/CokeOven.java new file mode 100644 index 00000000..4ccbe5c7 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/CokeOven.java @@ -0,0 +1,84 @@ +package com.drmangotea.tfmg.recipes.jei.machines; + + +import com.drmangotea.tfmg.registry.TFMGBlocks; +import com.jozufozu.flywheel.core.PartialModel; +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.blaze3d.vertex.VertexConsumer; +import com.mojang.math.Vector3f; +import com.simibubi.create.AllBlocks; +import com.simibubi.create.AllPartialModels; +import com.simibubi.create.AllSpriteShifts; +import com.simibubi.create.compat.jei.category.animations.AnimatedKinetics; +import com.simibubi.create.content.processing.burner.BlazeBurnerBlock; +import com.simibubi.create.foundation.block.render.SpriteShiftEntry; +import com.simibubi.create.foundation.render.CachedBufferer; +import com.simibubi.create.foundation.utility.AnimationTickHolder; +import net.minecraft.client.Minecraft; +import net.minecraft.client.renderer.LightTexture; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.util.Mth; +import net.minecraft.world.level.block.Blocks; + +public class CokeOven extends AnimatedKinetics { + + + + public CokeOven() {} + + @Override + public void draw(PoseStack matrixStack, int xOffset, int yOffset) { + matrixStack.pushPose(); + matrixStack.translate(xOffset, yOffset, 200); + matrixStack.mulPose(Vector3f.XP.rotationDegrees(-15.5f)); + matrixStack.mulPose(Vector3f.YP.rotationDegrees(22.5f)); + int scale = 23; + BlazeBurnerBlock.HeatLevel heatLevel = BlazeBurnerBlock.HeatLevel.SMOULDERING; + + + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,0,1) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,0,2) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,1,0) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,1,1) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,1,2) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,-1,0) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,-1,1) + .scale(scale) + .render(matrixStack); + blockElement(TFMGBlocks.COKE_OVEN.getDefaultState()) + .atLocal(0,-1,2) + .scale(scale) + .render(matrixStack); + + + matrixStack.scale(scale, -scale, scale); + matrixStack.translate(0, -1.8, 0); + matrixStack.popPose(); + } + + + +} diff --git a/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/Distillery.java b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/Distillery.java index eb845867..f217f4a4 100644 --- a/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/Distillery.java +++ b/src/main/java/com/drmangotea/tfmg/recipes/jei/machines/Distillery.java @@ -25,9 +25,7 @@ public class Distillery extends AnimatedKinetics { - public Distillery() { - - } + public Distillery() {} @Override public void draw(PoseStack matrixStack, int xOffset, int yOffset) { diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java index ad2bf64e..5daadfb5 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java @@ -9,6 +9,8 @@ import com.drmangotea.tfmg.content.deposits.surface_scanner.SurfaceScannerRender import com.drmangotea.tfmg.content.deposits.surface_scanner.SurfaceScannerTileEntity; import com.drmangotea.tfmg.content.machines.metal_processing.blast_furnace.blast_furnace_output.BlastFurnaceOutputBlockEntity; import com.drmangotea.tfmg.content.machines.metal_processing.blast_furnace.blast_furnace_output.BlastFurnaceRenderer; +import com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenBlockEntity; +import com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenRenderer; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillation_tower.DistillationControllerBlockEntity; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillation_tower.DistillationOutputBlockEntity; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillery.DistilleryControllerBlockEntity; @@ -170,6 +172,12 @@ public class TFMGBlockEntities { .validBlocks(TFMGBlocks.BLAST_FURNACE_OUTPUT) .register(); + public static final BlockEntityEntry COKE_OVEN = REGISTRATE + .blockEntity("coke_oven", CokeOvenBlockEntity::new) + .renderer(() -> CokeOvenRenderer::new) + .validBlocks(TFMGBlocks.COKE_OVEN) + .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 581c6477..b3263c5c 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java @@ -12,6 +12,8 @@ import com.drmangotea.tfmg.content.items.CoalCokeBlockItem; import com.drmangotea.tfmg.content.items.FossilstoneItem; import com.drmangotea.tfmg.content.deposits.surface_scanner.SurfaceScannerBlock; import com.drmangotea.tfmg.content.machines.metal_processing.blast_furnace.blast_furnace_output.BlastFurnaceOutputBlock; +import com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenBlock; +import com.drmangotea.tfmg.content.machines.metal_processing.coke_oven.CokeOvenGenerator; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillation_tower.DistillationControllerBlock; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillation_tower.DistillationOutputBlock; import com.drmangotea.tfmg.content.machines.oil_processing.distillation.distillery.DistilleryControllerBlock; @@ -41,6 +43,7 @@ import com.simibubi.create.content.fluids.pipes.SmartFluidPipeGenerator; import com.simibubi.create.content.fluids.pipes.valve.FluidValveBlock; import com.simibubi.create.content.kinetics.BlockStressDefaults; import com.simibubi.create.content.processing.AssemblyOperatorBlockItem; +import com.simibubi.create.content.redstone.smartObserver.SmartObserverGenerator; import com.simibubi.create.foundation.data.*; import com.tterrag.registrate.util.entry.BlockEntry; import net.minecraft.client.renderer.RenderType; @@ -364,7 +367,16 @@ public static final BlockEntry STEEL_DISTILLATION_OUTPU .register(); ////////// - + public static final BlockEntry COKE_OVEN = REGISTRATE.block("coke_oven", CokeOvenBlock::new) + .initialProperties(() -> Blocks.BRICKS) + .properties(p -> p.color(MaterialColor.COLOR_RED)) + .properties(p -> p.requiresCorrectToolForDrops()) + .blockstate(new CokeOvenGenerator()::generate) + .transform(pickaxeOnly()) + .item() + .transform(customItemModel()) + .lang("Coke Oven") + .register(); diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java index da7c4b37..8ec95982 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java @@ -18,6 +18,11 @@ import java.util.Map; public class TFMGPartialModels { public static final PartialModel + + 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"), + COKE_OVEN_DOOR_RIGHT_TOP = block("coke_oven/door_right_top"), COAL_COKE_DUST_LAYER = block("coal_coke_dust_layer"), PUMPJACK_HAMMER = block("pumpjack/hammer_holder"), PUMPJACK_FRONT_ROPE = block("pumpjack/pumpjack_front_rope"), diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java index b428f3da..6eff2545 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGRecipeTypes.java @@ -2,8 +2,10 @@ package com.drmangotea.tfmg.registry; import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.recipes.coking.CokingRecipe; import com.drmangotea.tfmg.recipes.distillation.DistillationRecipe; import com.drmangotea.tfmg.recipes.distillation.AdvancedDistillationRecipe; +import com.drmangotea.tfmg.recipes.industrial_blasting.IndustrialBlastingRecipe; import com.google.common.collect.ImmutableSet; import com.simibubi.create.content.processing.recipe.ProcessingRecipeBuilder.ProcessingRecipeFactory; import com.simibubi.create.content.processing.recipe.ProcessingRecipeSerializer; @@ -29,8 +31,11 @@ import java.util.function.Supplier; public enum TFMGRecipeTypes implements IRecipeTypeInfo { +INDUSTRIAL_BLASTING(IndustrialBlastingRecipe::new), +COKING(CokingRecipe::new), DISTILLATION(DistillationRecipe::new), -ADVANCED_DISTILLATION(AdvancedDistillationRecipe::new); +ADVANCED_DISTILLATION(AdvancedDistillationRecipe::new) +; private final ResourceLocation id; private final RegistryObject> serializerObject; diff --git a/src/main/resources/assets/tfmg/lang/default/interface.json b/src/main/resources/assets/tfmg/lang/default/interface.json index 281715a7..ddcb7d54 100644 --- a/src/main/resources/assets/tfmg/lang/default/interface.json +++ b/src/main/resources/assets/tfmg/lang/default/interface.json @@ -2,9 +2,11 @@ "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.percent_symbol": "%", "create.goggles.misc.dot_one": ".", "create.goggles.misc.dot_two": "..", "create.goggles.misc.dot_three": "...", + "create.goggles.misc.storage_info": "Storage Info:", "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", @@ -17,7 +19,7 @@ "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 Stats:", + "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", @@ -27,5 +29,12 @@ "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.blast_furnace.diameter.two": "Diameter: 2", + "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" } \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coal_coke_dust_layer.json b/src/main/resources/assets/tfmg/models/block/coal_coke_dust_layer.json index 9d2d1a3a..2be3d959 100644 --- a/src/main/resources/assets/tfmg/models/block/coal_coke_dust_layer.json +++ b/src/main/resources/assets/tfmg/models/block/coal_coke_dust_layer.json @@ -13,8 +13,7 @@ "east": {"uv": [0, 0, 16, 0], "texture": "#0"}, "south": {"uv": [0, 0, 16, 0], "texture": "#0"}, "west": {"uv": [0, 0, 16, 0], "texture": "#0"}, - "up": {"uv": [0, 0, 16, 16], "texture": "#0"}, - "down": {"uv": [0, 0, 16, 16], "texture": "#0"} + "up": {"uv": [0, 0, 16, 16], "texture": "#0"} } } ] diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block.json new file mode 100644 index 00000000..53f9369f --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_off.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_off.json new file mode 100644 index 00000000..552e12e2 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_off.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_bottom_off" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_on.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_on.json new file mode 100644 index 00000000..c968961f --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_bottom_on.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_bottom_on" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_casual.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_casual.json new file mode 100644 index 00000000..53f9369f --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_casual.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_off.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_off.json new file mode 100644 index 00000000..ce145676 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_off.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_middle_off" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_on.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_on.json new file mode 100644 index 00000000..2653bc57 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_middle_on.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_middle_on" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_off.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_off.json new file mode 100644 index 00000000..84ba4439 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_off.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_top_off" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_on.json b/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_on.json new file mode 100644 index 00000000..42b280fd --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/block_top_on.json @@ -0,0 +1,6 @@ +{ + "parent": "tfmg:block/coke_oven/controller", + "textures": { + "front": "tfmg:block/coke_oven_front_top_on" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/controller.json b/src/main/resources/assets/tfmg/models/block/coke_oven/controller.json new file mode 100644 index 00000000..7ff1fa34 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/controller.json @@ -0,0 +1,12 @@ +{ + "parent": "minecraft:block/cube", + "textures": { + "particle": "tfmg:block/coke_oven", + "down": "tfmg:block/coke_oven", + "up": "tfmg:block/coke_oven", + "north": "tfmg:block/coke_oven", + "east": "tfmg:block/coke_oven", + "south": "#front", + "west": "tfmg:block/coke_oven" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/door_left.json b/src/main/resources/assets/tfmg/models/block/coke_oven/door_left.json new file mode 100644 index 00000000..04f0a21c --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/door_left.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/coke_oven_door", + "particle": "tfmg:block/coke_oven_door" + }, + "elements": [ + { + "from": [0, 0, 16.01], + "to": [8, 16, 16.01], + "faces": { + "north": {"uv": [12, 0, 16, 8], "texture": "#0"}, + "east": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "south": {"uv": [8, 0, 12, 8], "texture": "#0"}, + "west": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "up": {"uv": [0, 0, 8, 0], "texture": "#0"}, + "down": {"uv": [0, 0, 8, 0], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/door_left_top.json b/src/main/resources/assets/tfmg/models/block/coke_oven/door_left_top.json new file mode 100644 index 00000000..e3150872 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/door_left_top.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/coke_oven_door", + "particle": "tfmg:block/coke_oven_door" + }, + "elements": [ + { + "from": [0, 0, 16.01], + "to": [8, 32, 16.01], + "faces": { + "north": {"uv": [4, 0, 8, 16], "texture": "#0"}, + "east": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "south": {"uv": [8, 0, 4, 16], "texture": "#0"}, + "west": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "up": {"uv": [0, 0, 8, 0], "texture": "#0"}, + "down": {"uv": [0, 0, 8, 0], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/door_right.json b/src/main/resources/assets/tfmg/models/block/coke_oven/door_right.json new file mode 100644 index 00000000..30f80251 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/door_right.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/coke_oven_door", + "particle": "tfmg:block/coke_oven_door" + }, + "elements": [ + { + "from": [8, 0, 16.01], + "to": [16, 16, 16.01], + "faces": { + "north": {"uv": [16, 0, 12, 8], "texture": "#0"}, + "east": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "south": {"uv": [12, 0, 16, 8], "texture": "#0"}, + "west": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "up": {"uv": [0, 0, 8, 0], "texture": "#0"}, + "down": {"uv": [0, 0, 8, 0], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/coke_oven/door_right_top.json b/src/main/resources/assets/tfmg/models/block/coke_oven/door_right_top.json new file mode 100644 index 00000000..7c394378 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/coke_oven/door_right_top.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/coke_oven_door", + "particle": "tfmg:block/coke_oven_door" + }, + "elements": [ + { + "from": [8, 0, 16.01], + "to": [16, 32, 16.01], + "faces": { + "north": {"uv": [0, 0, 4, 16], "texture": "#0"}, + "east": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "south": {"uv": [4, 0, 0, 16], "texture": "#0"}, + "west": {"uv": [0, 0, 0, 16], "texture": "#0"}, + "up": {"uv": [0, 0, 8, 0], "texture": "#0"}, + "down": {"uv": [0, 0, 8, 0], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven.png b/src/main/resources/assets/tfmg/textures/block/coke_oven.png new file mode 100644 index 00000000..0ee3fd99 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_door.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_door.png new file mode 100644 index 00000000..21139309 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_door.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_off.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_off.png new file mode 100644 index 00000000..66ca8a74 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_off.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_on.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_on.png new file mode 100644 index 00000000..ff80b44c Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_bottom_on.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_off.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_off.png new file mode 100644 index 00000000..c2eb49c3 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_off.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_on.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_on.png new file mode 100644 index 00000000..3b1a0b86 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_middle_on.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_off.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_off.png new file mode 100644 index 00000000..7bb321d0 Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_off.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_on.png b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_on.png new file mode 100644 index 00000000..04d0fabf Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/coke_oven_front_top_on.png differ diff --git a/src/main/resources/data/tfmg/recipes/coking/test_coking.json b/src/main/resources/data/tfmg/recipes/coking/test_coking.json new file mode 100644 index 00000000..b17aba93 --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/coking/test_coking.json @@ -0,0 +1,22 @@ +{ + "type": "tfmg:coking", + "ingredients": [ + { + "count": 20, + "item": "minecraft:coal" + } + ], + "processingTime": 200, + "results": [ + { + "count": 20, + "item": "tfmg:coal_coke" + } + , + { + "fluid": "tfmg:heavy_oil", + "amount": 4 + } + + ] +} \ No newline at end of file diff --git a/src/main/resources/data/tfmg/recipes/coking/test_coking_aaaaa.json b/src/main/resources/data/tfmg/recipes/coking/test_coking_aaaaa.json new file mode 100644 index 00000000..a5a4d6f4 --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/coking/test_coking_aaaaa.json @@ -0,0 +1,19 @@ +{ + "type": "tfmg:coking", + "ingredients": [ + { + "item": "minecraft:sand" + } + ], + "processingTime": 200, + "results": [ + { + "item": "minecraft:red_sand" + }, + { + "fluid": "tfmg:creosote", + "amount": 30 + } + + ] +} \ No newline at end of file diff --git a/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking.json b/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking.json new file mode 100644 index 00000000..fe13c5ee --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking.json @@ -0,0 +1,21 @@ +{ + "type": "tfmg:industrial_blasting", + "ingredients": [ + { + "count": 20, + "item": "minecraft:coal" + } + ], + "processingTime": 200, + "results": [ + { + "fluid": "tfmg:creosote", + "amount": 30 + }, + { + "fluid": "tfmg:heavy_oil", + "amount": 4 + } + + ] +} \ No newline at end of file diff --git a/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking_aaaaa.json b/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking_aaaaa.json new file mode 100644 index 00000000..7f8c9dca --- /dev/null +++ b/src/main/resources/data/tfmg/recipes/industrial_blasting/test_coking_aaaaa.json @@ -0,0 +1,20 @@ +{ + "type": "tfmg:industrial_blasting", + "ingredients": [ + { + "item": "minecraft:sand" + } + ], + "processingTime": 200, + "results": [ + { + "fluid": "tfmg:creosote", + "amount": 30 + }, + { + "fluid": "tfmg:creosote", + "amount": 30 + } + + ] +} \ No newline at end of file