diff --git a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a index 07329aec..4ff42089 100644 --- a/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a +++ b/src/generated/resources/.cache/ad795fb8576279849034d802e60366ec43bb396a @@ -1,10 +1,11 @@ -// 1.19.2 2023-08-30T23:23:40.7821017 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-08-31T14:31:49.9051322 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)] 9ca537517fb8baeff3d4e4137c93aebd6b874c81 assets/tfmg/blockstates/cast_iron_block.json c67b91a7fd9f16cd2d7eaa92dd9b945042d58130 assets/tfmg/blockstates/concrete.json dca4728ef33ca9d54fb55d707761c2eeb77c32b1 assets/tfmg/blockstates/cooling_fluid.json fa1fa0509cd94e57da7624b5d094c228d6b92593 assets/tfmg/blockstates/creosote.json a9b81338133077138f447a0d159f094edb61242a assets/tfmg/blockstates/crude_oil_fluid.json 03983ce3de10310cd75b98f17c9161653b7034cd assets/tfmg/blockstates/diesel.json +f16d1cf03e5053455ea485f7aa53a88206f61749 assets/tfmg/blockstates/formwork_block.json b0a3f4da5d9efdd01800c8b9738aee194565c6e7 assets/tfmg/blockstates/gasoline.json c7aa764cc11ee837deeed68c9c2d8567ea078f5c assets/tfmg/blockstates/heavy_machinery_casing.json dea24edfcb504c6c74560174a94bd7d3e5d58e76 assets/tfmg/blockstates/heavy_oil.json @@ -17,8 +18,8 @@ ebd6804b999acea36abbf07c2381ee6dee0d7a16 assets/tfmg/blockstates/napalm.json 89f2902010903aad686571ef37c781b111147456 assets/tfmg/blockstates/naphtha.json e6983072149d1a9a2f4d39e4e1feac599ff7413e assets/tfmg/blockstates/steel_block.json df44115876045e6f863de2f8be6a9166b336a2f1 assets/tfmg/blockstates/steel_casing.json -b68d0d30eb993662524158c536547497dc507204 assets/tfmg/lang/en_ud.json -841085ce8022c36f4e4a65b8f0133e6f815d9668 assets/tfmg/lang/en_us.json +b9953b7a05c4747eee192dc2b66943fe7b45db84 assets/tfmg/lang/en_ud.json +13043ade5d18c12e300962f4cc9d06ecc02e7089 assets/tfmg/lang/en_us.json 37789d06ec6cfc0312be7b1b66ac1ec6403d4516 assets/tfmg/models/block/cast_iron_block.json 75c31d328fc5d6d46c8b43e8bde7504f4e51dadc assets/tfmg/models/block/concrete.json 80fb4a90f861992322bfd63f1232593e8cce708e assets/tfmg/models/block/cooling_fluid.json @@ -44,6 +45,7 @@ df4e7fa8f3f60908f58794528a8db60dce7d0135 assets/tfmg/models/item/copper_grenade. 0abf2b2d61995c4fd3e3c88656e740ffe0a2f083 assets/tfmg/models/item/creosote_bucket.json e857cfbd6dfd0fe4b38e48f432f7a92e82dc5e22 assets/tfmg/models/item/crude_oil_fluid_bucket.json 3497bcbaee50b2f766de659043bf3c36823b570d assets/tfmg/models/item/diesel_bucket.json +a11a0b5a9887ba342d80b574a7f2c3dc5cdd7372 assets/tfmg/models/item/formwork_block.json ed2830b2988403aebaca633b2e315878b41f7503 assets/tfmg/models/item/gasoline_bucket.json 3fdff9e88db39939ee31968358eb51c060006766 assets/tfmg/models/item/heavy_machinery_casing.json f3bea42a905b7df9395bda18f751e2ee0c023e65 assets/tfmg/models/item/heavy_oil_bucket.json @@ -75,11 +77,12 @@ c98956ac34e02a8c1c801122486771ef89fb640b data/forge/tags/items/storage_blocks.js 7c5615c56bb169570a061f052ebb1f5115760c16 data/forge/tags/items/storage_blocks/cast_iron.json 37b1c9c3ae722d8110db48015993ede3e194c0a0 data/forge/tags/items/storage_blocks/steel.json c98956ac34e02a8c1c801122486771ef89fb640b data/minecraft/tags/blocks/beacon_base_blocks.json -2b45163d462fba0e86bb1ac8fc299509fbe1e58d data/minecraft/tags/blocks/mineable/axe.json +ecfc3593fe0f3f0b5eff61fb1a2a445b16cda216 data/minecraft/tags/blocks/mineable/axe.json b64e309f3dfd304a74fc9c4e1a97b2ea3c2c02e8 data/minecraft/tags/blocks/mineable/pickaxe.json 7f922e1459e98ee497c359655ee2b408bf84e4f4 data/minecraft/tags/blocks/needs_iron_tool.json 60857d034446187e758de87644a80a7bc4d6b150 data/tfmg/loot_tables/blocks/cast_iron_block.json d32a75f20ca3f2da6ba69b0a91e295c63f65de92 data/tfmg/loot_tables/blocks/concrete.json +51818c7cf522c10c409c8737fdc30a58d7560f71 data/tfmg/loot_tables/blocks/formwork_block.json 661cc61f9c13ddf8c6bf06470defa93170e8ee7f data/tfmg/loot_tables/blocks/heavy_machinery_casing.json 7da9b20012e584104331da961756d6c1d02682b5 data/tfmg/loot_tables/blocks/napalm_bomb.json 01298989d0fe79936cdfa1e6cc07fd05f143ae09 data/tfmg/loot_tables/blocks/steel_block.json diff --git a/src/generated/resources/assets/tfmg/blockstates/formwork_block.json b/src/generated/resources/assets/tfmg/blockstates/formwork_block.json new file mode 100644 index 00000000..d210e1a7 --- /dev/null +++ b/src/generated/resources/assets/tfmg/blockstates/formwork_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "tfmg:block/formwork_block/block_base" + } + } +} \ 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 4daeb8d9..5bbbfe03 100644 --- a/src/generated/resources/assets/tfmg/lang/en_ud.json +++ b/src/generated/resources/assets/tfmg/lang/en_ud.json @@ -5,6 +5,7 @@ "block.tfmg.creosote": "ǝʇosoǝɹƆ", "block.tfmg.crude_oil_fluid": "pınןℲ ןıO ǝpnɹƆ", "block.tfmg.diesel": "ןǝsǝıᗡ", + "block.tfmg.formwork_block": "ʞɔoןᗺ ʞɹoʍɯɹoℲ", "block.tfmg.gasoline": "ǝuıןosɐ⅁", "block.tfmg.heavy_machinery_casing": "buısɐƆ ʎɹǝuıɥɔɐW ʎʌɐǝH", "block.tfmg.heavy_oil": "ןıO ʎʌɐǝH", diff --git a/src/generated/resources/assets/tfmg/lang/en_us.json b/src/generated/resources/assets/tfmg/lang/en_us.json index f9eec415..a062c1b5 100644 --- a/src/generated/resources/assets/tfmg/lang/en_us.json +++ b/src/generated/resources/assets/tfmg/lang/en_us.json @@ -5,6 +5,7 @@ "block.tfmg.creosote": "Creosote", "block.tfmg.crude_oil_fluid": "Crude Oil Fluid", "block.tfmg.diesel": "Diesel", + "block.tfmg.formwork_block": "Formwork Block", "block.tfmg.gasoline": "Gasoline", "block.tfmg.heavy_machinery_casing": "Heavy Machinery Casing", "block.tfmg.heavy_oil": "Heavy Oil", diff --git a/src/generated/resources/assets/tfmg/models/item/formwork_block.json b/src/generated/resources/assets/tfmg/models/item/formwork_block.json new file mode 100644 index 00000000..8abbc956 --- /dev/null +++ b/src/generated/resources/assets/tfmg/models/item/formwork_block.json @@ -0,0 +1,3 @@ +{ + "parent": "tfmg:block/formwork_block/block_base" +} \ No newline at end of file diff --git a/src/generated/resources/data/minecraft/tags/blocks/mineable/axe.json b/src/generated/resources/data/minecraft/tags/blocks/mineable/axe.json index bbe4537f..2fb68493 100644 --- a/src/generated/resources/data/minecraft/tags/blocks/mineable/axe.json +++ b/src/generated/resources/data/minecraft/tags/blocks/mineable/axe.json @@ -1,6 +1,7 @@ { "values": [ "tfmg:steel_casing", - "tfmg:heavy_machinery_casing" + "tfmg:heavy_machinery_casing", + "tfmg:formwork_block" ] } \ No newline at end of file diff --git a/src/generated/resources/data/tfmg/loot_tables/blocks/formwork_block.json b/src/generated/resources/data/tfmg/loot_tables/blocks/formwork_block.json new file mode 100644 index 00000000..c82759a6 --- /dev/null +++ b/src/generated/resources/data/tfmg/loot_tables/blocks/formwork_block.json @@ -0,0 +1,20 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "tfmg:formwork_block" + } + ], + "rolls": 1.0 + } + ] +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/CreateTFMG.java b/src/main/java/com/drmangotea/tfmg/CreateTFMG.java index c02f9269..4b6f3ed2 100644 --- a/src/main/java/com/drmangotea/tfmg/CreateTFMG.java +++ b/src/main/java/com/drmangotea/tfmg/CreateTFMG.java @@ -36,6 +36,7 @@ public class CreateTFMG TFMGBlocks.register(); TFMGItems.register(); + TFMGBlockEntities.register(); TFMGEntityTypes.register(); TFMGCreativeModeTabs.init(); TFMGFluids.register(); diff --git a/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java b/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java index 9c4935ef..6aba6106 100644 --- a/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java +++ b/src/main/java/com/drmangotea/tfmg/CreateTFMGClient.java @@ -1,6 +1,7 @@ package com.drmangotea.tfmg; +import com.drmangotea.tfmg.registry.TFMGPartialModels; import net.minecraftforge.eventbus.api.IEventBus; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent; @@ -10,7 +11,7 @@ public class CreateTFMGClient { public CreateTFMGClient() { IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus(); - //CIPartialModels.init(); + TFMGPartialModels.init(); modEventBus.register(this); } diff --git a/src/main/java/com/drmangotea/tfmg/base/TFMGBuilderTransformers.java b/src/main/java/com/drmangotea/tfmg/base/TFMGBuilderTransformers.java new file mode 100644 index 00000000..b26f30d6 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/base/TFMGBuilderTransformers.java @@ -0,0 +1,28 @@ +package com.drmangotea.tfmg.base; + +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkBlock; +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkBlockEntity; +import com.simibubi.create.AllTags; +import com.simibubi.create.content.contraptions.behaviour.DoorMovingInteraction; +import com.simibubi.create.content.decoration.slidingDoor.SlidingDoorBlock; +import com.simibubi.create.content.decoration.slidingDoor.SlidingDoorMovementBehaviour; +import com.simibubi.create.foundation.data.AssetLookup; +import com.tterrag.registrate.builders.BlockBuilder; +import com.tterrag.registrate.util.nullness.NonNullUnaryOperator; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.data.loot.BlockLoot; +import net.minecraft.tags.BlockTags; +import net.minecraft.tags.ItemTags; +import net.minecraft.world.level.material.Material; +import net.minecraft.world.level.material.MaterialColor; +import net.minecraftforge.client.model.generators.ModelFile; + +import static com.simibubi.create.AllInteractionBehaviours.interactionBehaviour; +import static com.simibubi.create.AllMovementBehaviours.movementBehaviour; +import static com.simibubi.create.foundation.data.TagGen.axeOnly; + + +public class TFMGBuilderTransformers { + + +} diff --git a/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlock.java b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlock.java new file mode 100644 index 00000000..689e94c8 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlock.java @@ -0,0 +1,23 @@ +package com.drmangotea.tfmg.content.concrete.formwork; + +import com.drmangotea.tfmg.registry.TFMGBlockEntities; +import com.simibubi.create.content.equipment.wrench.IWrenchable; +import com.simibubi.create.foundation.block.IBE; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.entity.BlockEntityType; + +public class FormWorkBlock extends Block implements IWrenchable, IBE { + public FormWorkBlock(Properties p_49795_) { + super(p_49795_); + } + + @Override + public Class getBlockEntityClass() { + return FormWorkBlockEntity.class; + } + + @Override + public BlockEntityType getBlockEntityType() { + return TFMGBlockEntities.FORMWORK.get(); + } +} diff --git a/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlockEntity.java b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlockEntity.java new file mode 100644 index 00000000..4930871a --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkBlockEntity.java @@ -0,0 +1,215 @@ +package com.drmangotea.tfmg.content.concrete.formwork; + +import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.content.machines.TFMGMachineBlockEntity; +import com.drmangotea.tfmg.registry.TFMGFluids; +import com.simibubi.create.api.connectivity.ConnectivityHandler; +import com.simibubi.create.content.fluids.tank.FluidTankBlockEntity; +import com.simibubi.create.foundation.fluid.SmartFluidTank; +import com.simibubi.create.foundation.utility.animation.LerpedFloat; +import net.minecraft.core.BlockPos; +import net.minecraft.nbt.CompoundTag; +import net.minecraft.world.level.block.entity.BlockEntity; +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.FluidType; +import net.minecraftforge.fluids.capability.IFluidHandler; +import net.minecraftforge.fluids.capability.templates.FluidTank; + +public class FormWorkBlockEntity extends TFMGMachineBlockEntity { + + public boolean east = true; + public boolean west = true; + public boolean north = true; + public boolean south = true; + public boolean bottom = true; + + protected FluidTank tankInventory; + + + public LerpedFloat fluidLevel = LerpedFloat.linear(); + public FormWorkBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + tankInventory = createInventory(); + fluidCapability = LazyOptional.of(() -> tankInventory); + tank1.forbidInsertion(); + tank2.forbidExtraction(); + } + protected SmartFluidTank createInventory() { + return new SmartFluidTank(1000, this::onFluidStackChanged){ + @Override + public boolean isFluidValid(FluidStack stack) { + return stack.getFluid().isSame(TFMGFluids.LIQUID_CONCRETE.getSource()); + } + @Override + public FluidStack drain(FluidStack resource, FluidAction action) { + return FluidStack.EMPTY; + } + }; + } + + + @Override + public void tick() { + super.tick(); + fluidLevel.chase(tankInventory.getFluidAmount(), 0.3f, LerpedFloat.Chaser.EXP); + fluidLevel.tickChaser(); + + BlockEntity blockEntityBelow = level.getBlockEntity(this.getBlockPos().below()); + BlockEntity blockEntityNorth = level.getBlockEntity(this.getBlockPos().north()); + BlockEntity blockEntityWest = level.getBlockEntity(this.getBlockPos().west()); + BlockEntity blockEntityEast = level.getBlockEntity(this.getBlockPos().east()); + BlockEntity blockEntitySouth = level.getBlockEntity(this.getBlockPos().south()); + + + bottom = !(blockEntityBelow instanceof FormWorkBlockEntity); + east = !(blockEntityEast instanceof FormWorkBlockEntity); + west = !(blockEntityWest instanceof FormWorkBlockEntity); + north = !(blockEntityNorth instanceof FormWorkBlockEntity); + south = !(blockEntitySouth instanceof FormWorkBlockEntity); + for (int x = 0; x < 30; x++) { + for (int i = 0; i < 5; i++) { + BlockEntity CheckedBE = null; + + if (i == 0) { + CheckedBE = level.getBlockEntity(this.getBlockPos().below()); + } + if (i == 1) { + CheckedBE = level.getBlockEntity(this.getBlockPos().east()); + } + if (i == 2) { + CheckedBE = level.getBlockEntity(this.getBlockPos().west()); + } + if (i == 3) { + CheckedBE = level.getBlockEntity(this.getBlockPos().north()); + } + if (i == 4) { + CheckedBE = level.getBlockEntity(this.getBlockPos().south()); + } + + if (CheckedBE instanceof FormWorkBlockEntity) { + if(((FormWorkBlockEntity) CheckedBE).tankInventory.getFluidAmount()>this.tankInventory.getFluidAmount()&&i!=0) + continue; + + FluidTank checkedTank = ((FormWorkBlockEntity) CheckedBE).tankInventory; + if (checkedTank.getFluidAmount() < 1000) { + if(checkedTank.getFluidAmount()>=995&&tankInventory.getFluidAmount()>0){ + checkedTank.setFluid(new FluidStack(TFMGFluids.LIQUID_CONCRETE.getSource(), checkedTank.getFluidAmount()+1)); + //tankInventory.drain(1, IFluidHandler.FluidAction.EXECUTE); + // continue; + } + + int reducedAmount = tankInventory.getFluidAmount() / 8; + + if (tankInventory.getFluidAmount() != 0) + reducedAmount = 1; + int newFluidAmount = checkedTank.getFluidAmount() + reducedAmount; + + int toRemove = reducedAmount; + //if full + if (newFluidAmount > 1000) { + continue; + // int amountModifier = newFluidAmount - 1000; + // newFluidAmount -= amountModifier; + // toRemove = reducedAmount - amountModifier; + } + // + checkedTank.setFluid(new FluidStack(TFMGFluids.LIQUID_CONCRETE.getSource(), newFluidAmount)); + tankInventory.drain(1, IFluidHandler.FluidAction.EXECUTE); + + } + } + } + } + + +/* + BlockPos below = this.getBlockPos().below(); + + BlockPos west = this.getBlockPos().west(); + BlockPos east = this.getBlockPos().east(); + BlockPos north = this.getBlockPos().north(); + BlockPos south = this.getBlockPos().south(); + + if(level.getBlockEntity(below) instanceof FormWorkBlockEntity){ + bottom = false; + }else bottom = true; + if(level.getBlockEntity(west) instanceof FormWorkBlockEntity){ + bottom = false; + }else bottom = true; + if(level.getBlockEntity(east) instanceof FormWorkBlockEntity){ + bottom = false; + }else bottom = true; + if(level.getBlockEntity(north) instanceof FormWorkBlockEntity){ + bottom = false; + }else bottom = true; + if(level.getBlockEntity(south) instanceof FormWorkBlockEntity){ + bottom = false; + }else bottom = true; + + + */ +} + + + protected void onFluidStackChanged(FluidStack newFluidStack) { + if (!hasLevel()) + return; + + + + if (!level.isClientSide) { + setChanged(); + sendData(); + } + + + } + public float getFillState() { + return (float) tankInventory.getFluidAmount() / tankInventory.getCapacity(); + } + + @Override + protected void read(CompoundTag compound, boolean clientPacket) { + super.read(compound, clientPacket); + + bottom = compound.getBoolean("Bottom"); + + east = compound.getBoolean("East"); + west = compound.getBoolean("West"); + north = compound.getBoolean("North"); + south = compound.getBoolean("South"); + tankInventory.readFromNBT(compound.getCompound("TankContent")); + + + + } + + @Override + public void write(CompoundTag compound, boolean clientPacket) { + super.write(compound, clientPacket); + + + compound.putBoolean("Bottom", bottom); + + compound.putBoolean("East", east); + compound.putBoolean("West", west); + compound.putBoolean("North", north); + compound.putBoolean("South", south); + compound.put("TankContent", tankInventory.writeToNBT(new CompoundTag())); + + + + } + + + public LerpedFloat getFluidLevel() { + return fluidLevel; + } + + + + +} diff --git a/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkGenerator.java b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkGenerator.java new file mode 100644 index 00000000..c6eb8d47 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkGenerator.java @@ -0,0 +1,38 @@ +package com.drmangotea.tfmg.content.concrete.formwork; + +import com.simibubi.create.Create; +import com.simibubi.create.content.logistics.chute.ChuteBlock; +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.core.Direction; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraftforge.client.model.generators.ModelFile; + +public class FormWorkGenerator extends SpecialBlockStateGen { + + @Override + protected int getXRotation(BlockState state) { + return 0; + } + + @Override + protected int getYRotation(BlockState state) { + return 0; + } + + @Override + public ModelFile getModel(DataGenContext ctx, RegistrateBlockstateProvider prov, + BlockState state) { + + + + return AssetLookup.partialBaseModel(ctx, prov, "base"); + } + + +} diff --git a/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkRenderer.java b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkRenderer.java new file mode 100644 index 00000000..e50514b6 --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/concrete/formwork/FormWorkRenderer.java @@ -0,0 +1,142 @@ +package com.drmangotea.tfmg.content.concrete.formwork; + + +import com.drmangotea.tfmg.CreateTFMG; +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.AllPartialModels; +import com.simibubi.create.content.fluids.tank.FluidTankBlockEntity; +import com.simibubi.create.foundation.blockEntity.renderer.SafeBlockEntityRenderer; +import com.simibubi.create.foundation.fluid.FluidRenderer; +import com.simibubi.create.foundation.render.CachedBufferer; + +import com.simibubi.create.foundation.utility.Iterate; +import com.simibubi.create.foundation.utility.animation.LerpedFloat; + +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider; +import net.minecraft.core.Direction; +import net.minecraft.util.Mth; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraftforge.fluids.FluidStack; +import net.minecraftforge.fluids.capability.templates.FluidTank; + +public class FormWorkRenderer extends SafeBlockEntityRenderer { + + public FormWorkRenderer(BlockEntityRendererProvider.Context context) {} + + @Override + protected void renderSafe(FormWorkBlockEntity be, float partialTicks, PoseStack ms, MultiBufferSource buffer, + int light, int overlay) { + + renderConcreteInside(be,partialTicks,ms,buffer,light,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); + + if(be.north) { + CachedBufferer.partial(TFMGPartialModels.FORMWORK_SIDE, blockState) + .unCentre() + .light(light) + .renderInto(ms, vb); + } + if(be.east) { + CachedBufferer.partial(TFMGPartialModels.FORMWORK_SIDE, blockState) + .rotateY(270) + .unCentre() + .light(light) + .renderInto(ms, vb); + } + if(be.south) { + CachedBufferer.partial(TFMGPartialModels.FORMWORK_SIDE, blockState) + .rotateY(180) + .unCentre() + .light(light) + .renderInto(ms, vb); + } + + if(be.west) { + CachedBufferer.partial(TFMGPartialModels.FORMWORK_SIDE, blockState) + .rotateY(90) + .unCentre() + .light(light) + .renderInto(ms, vb); + } + /// + if(be.bottom) { + CachedBufferer.partial(TFMGPartialModels.FORMWORK_BOTTOM, blockState) + .unCentre() + .light(light) + .renderInto(ms, vb); + + } + + + ms.popPose(); + + } + + + protected void renderConcreteInside(FormWorkBlockEntity be, float partialTicks, PoseStack ms, MultiBufferSource buffer, + int light, int overlay) { + LerpedFloat fluidLevel = be.getFluidLevel(); + + if (fluidLevel == null) { + return; + } + float level = fluidLevel.getValue(partialTicks); + + float capHeight = 1 / 4f; + float tankHullWidth = 1 / 16f + 1 / 128f; + float minPuddleHeight = 1 / 16f; + + + // float level = fluidLevel.getValue(partialTicks); + // if (level < 1 / (512f * 1)) + // return; + // float clampedLevel = Mth.clamp(level * 1, 0, 1); + + FluidTank tank = be.tankInventory; + FluidStack fluidStack = tank.getFluid(); + + if (fluidStack.isEmpty()) + return; + + + + if(be.getLevel().getBlockEntity(be.getBlockPos().below())instanceof FormWorkBlockEntity){ + if(((FormWorkBlockEntity) be.getLevel().getBlockEntity(be.getBlockPos().below())).tankInventory.getFluidAmount()<1000){ + be.fluidLevel.setValue(0); + return; + } + + } + + + + ms.pushPose(); + // ms.translate(0, clampedLevel - 1, 0); + FluidRenderer.renderFluidBox(fluidStack, 0, 0, 0, 1, be.getFluidLevel().getValue(partialTicks)/1000, 1, buffer, ms, light, false); + ms.popPose(); + + + } + + + + + + @Override + public boolean shouldRenderOffScreen(FormWorkBlockEntity te) { + return false; + } + +} \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java b/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java new file mode 100644 index 00000000..ecd5570d --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/content/machines/TFMGMachineBlockEntity.java @@ -0,0 +1,146 @@ +package com.drmangotea.tfmg.content.machines; + +import com.simibubi.create.content.equipment.goggles.IHaveGoggleInformation; +import com.simibubi.create.foundation.blockEntity.SmartBlockEntity; +import com.simibubi.create.foundation.blockEntity.behaviour.BlockEntityBehaviour; +import com.simibubi.create.foundation.blockEntity.behaviour.fluid.SmartFluidTankBehaviour; +import com.simibubi.create.foundation.fluid.CombinedTankWrapper; +import com.simibubi.create.foundation.utility.Couple; +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.network.chat.Component; +import net.minecraft.world.level.block.entity.BlockEntityType; +import net.minecraft.world.level.block.state.BlockState; +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 javax.annotation.Nonnull; +import java.util.List; +import java.util.Optional; + +public class TFMGMachineBlockEntity extends SmartBlockEntity implements IHaveGoggleInformation { + public SmartFluidTankBehaviour tank1; + public SmartFluidTankBehaviour tank2; + + private boolean contentsChanged; + + protected LazyOptional fluidCapability; + + public TFMGMachineBlockEntity(BlockEntityType type, BlockPos pos, BlockState state) { + super(type, pos, state); + tank1.forbidExtraction(); + tank2.forbidInsertion(); + + contentsChanged = true; + + } + + + + @Override + public void addBehaviours(List behaviours) { + tank1 = new SmartFluidTankBehaviour(SmartFluidTankBehaviour.INPUT, this, 1, 1000, true) + .whenFluidUpdates(() -> contentsChanged = true); + + tank2 = new SmartFluidTankBehaviour(SmartFluidTankBehaviour.OUTPUT, this, 1, 1000, true) + .whenFluidUpdates(() -> contentsChanged = true) + .forbidInsertion(); + behaviours.add(tank1); + behaviours.add(tank1); + + fluidCapability = LazyOptional.of(() -> { + LazyOptional inputCap = tank1.getCapability(); + LazyOptional outputCap = tank2.getCapability(); + return new CombinedTankWrapper(outputCap.orElse(null), inputCap.orElse(null)); + }); + } + + @Override + public void invalidate() { + super.invalidate(); + + fluidCapability.invalidate(); + } + @Nonnull + @Override + public LazyOptional getCapability(@Nonnull Capability cap, Direction side) { + + if (cap == CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY) + return fluidCapability.cast(); + return super.getCapability(cap, side); + } + @Override + public void notifyUpdate() { + super.notifyUpdate(); + } + + + + + @Override + 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/registry/TFMGBlockEntities.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java index 5130f44f..d0b99d57 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockEntities.java @@ -1,4 +1,35 @@ package com.drmangotea.tfmg.registry; +import com.drmangotea.tfmg.CreateTFMG; +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkBlockEntity; +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkRenderer; +import com.simibubi.create.content.fluids.pipes.FluidPipeBlockEntity; +import com.simibubi.create.content.fluids.pipes.StraightPipeBlockEntity; +import com.simibubi.create.content.fluids.pipes.TransparentStraightPipeRenderer; +import com.simibubi.create.content.fluids.pump.PumpBlockEntity; +import com.simibubi.create.content.fluids.pump.PumpCogInstance; +import com.simibubi.create.content.fluids.pump.PumpRenderer; +import com.simibubi.create.content.kinetics.base.HalfShaftInstance; +import com.simibubi.create.content.kinetics.base.HorizontalHalfShaftInstance; +import com.simibubi.create.content.kinetics.simpleRelays.BracketedKineticBlockEntity; +import com.simibubi.create.content.kinetics.simpleRelays.SimpleKineticBlockEntity; +import com.simibubi.create.foundation.data.CreateRegistrate; +import com.tterrag.registrate.util.entry.BlockEntityEntry; + +import static com.drmangotea.tfmg.CreateTFMG.REGISTRATE; + + public class TFMGBlockEntities { + + + + public static final BlockEntityEntry FORMWORK = REGISTRATE + .blockEntity("formwork", FormWorkBlockEntity::new) + .renderer(() -> FormWorkRenderer::new) + .validBlocks(TFMGBlocks.FORMWORK_BLOCK) + .register(); + + + + public static void register() {} } diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockStateGen.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockStateGen.java deleted file mode 100644 index bd5bf54b..00000000 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlockStateGen.java +++ /dev/null @@ -1,15 +0,0 @@ -package com.drmangotea.tfmg.registry; - -import com.tterrag.registrate.providers.DataGenContext; -import com.tterrag.registrate.providers.RegistrateBlockstateProvider; -import com.tterrag.registrate.util.nullness.NonNullBiConsumer; -import net.minecraft.world.level.block.Block; - -public class TFMGBlockStateGen { - - - public static NonNullBiConsumer, RegistrateBlockstateProvider> nothingLol( - String path) { - return null; - } -} diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java index a4a9a859..b6304601 100644 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGBlocks.java @@ -1,20 +1,21 @@ package com.drmangotea.tfmg.registry; +import com.drmangotea.tfmg.base.TFMGBuilderTransformers; import com.drmangotea.tfmg.base.TFMGSpriteShifts; +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkBlock; +import com.drmangotea.tfmg.content.concrete.formwork.FormWorkGenerator; import com.drmangotea.tfmg.content.gadgets.explosives.napalm.NapalmBombBlock; -import com.drmangotea.tfmg.content.gadgets.explosives.thermite_grenades.fire.BlueFireBlock; -import com.drmangotea.tfmg.content.gadgets.explosives.thermite_grenades.fire.GreenFireBlock; -import com.simibubi.create.AllCreativeModeTabs; -import com.simibubi.create.AllSpriteShifts; -import com.simibubi.create.Create; import com.simibubi.create.content.decoration.encasing.CasingBlock; import com.simibubi.create.content.decoration.encasing.EncasedCTBehaviour; +import com.simibubi.create.content.logistics.chute.ChuteGenerator; import com.simibubi.create.foundation.data.BuilderTransformers; import com.tterrag.registrate.util.entry.BlockEntry; import net.minecraft.tags.BlockTags; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.SoundType; +import net.minecraft.world.level.block.state.BlockBehaviour; +import net.minecraft.world.level.material.Material; import net.minecraft.world.level.material.MaterialColor; import net.minecraftforge.common.Tags; @@ -23,8 +24,7 @@ import static com.drmangotea.tfmg.CreateTFMG.REGISTRATE; import static com.simibubi.create.foundation.data.BlockStateGen.simpleCubeAll; import static com.simibubi.create.foundation.data.CreateRegistrate.casingConnectivity; import static com.simibubi.create.foundation.data.CreateRegistrate.connectedTextures; -import static com.simibubi.create.foundation.data.TagGen.pickaxeOnly; -import static com.simibubi.create.foundation.data.TagGen.tagBlockAndItem; +import static com.simibubi.create.foundation.data.TagGen.*; public class TFMGBlocks { @@ -60,7 +60,17 @@ public class TFMGBlocks { //-----------------------MACHINES---------------------------// - + public static final BlockEntry FORMWORK_BLOCK = + REGISTRATE.block("formwork_block", FormWorkBlock::new) + .initialProperties(Material.WOOD) + .properties(p -> p.color(MaterialColor.WOOD)) + .properties(p -> p.requiresCorrectToolForDrops()) + .properties(BlockBehaviour.Properties::noOcclusion) + .blockstate(new FormWorkGenerator()::generate) + .transform(axeOnly()) + .item() + .build() + .register(); diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java new file mode 100644 index 00000000..567aa08d --- /dev/null +++ b/src/main/java/com/drmangotea/tfmg/registry/TFMGPartialModels.java @@ -0,0 +1,54 @@ +package com.drmangotea.tfmg.registry; + + +import com.drmangotea.tfmg.CreateTFMG; +import com.jozufozu.flywheel.core.PartialModel; +import com.simibubi.create.content.fluids.FluidTransportBehaviour; +import com.simibubi.create.foundation.utility.Couple; +import com.simibubi.create.foundation.utility.Iterate; +import com.simibubi.create.foundation.utility.Lang; +import net.minecraft.core.Direction; +import net.minecraft.resources.ResourceLocation; + +import java.util.EnumMap; +import java.util.HashMap; +import java.util.Map; + + +public class TFMGPartialModels { + + public static final PartialModel + FORMWORK_BOTTOM = block("formwork_block/block_bottom"), + FORMWORK_SIDE = block("formwork_block/block_side"); + + public static final Map> FOLDING_DOORS = new HashMap<>(); + + public static final Map> STEEL_PIPE_ATTACHMENTS = + new EnumMap<>(FluidTransportBehaviour.AttachmentTypes.ComponentPartials.class); + + + static { + for (FluidTransportBehaviour.AttachmentTypes.ComponentPartials type : FluidTransportBehaviour.AttachmentTypes.ComponentPartials.values()) { + Map map = new HashMap<>(); + for (Direction d : Iterate.directions) { + String asId = Lang.asId(type.name()); + map.put(d, block("steel_fluid_pipe/" + asId + "/" + Lang.asId(d.getSerializedName()))); + } + STEEL_PIPE_ATTACHMENTS.put(type, map); + } + + putFoldingDoor("steel_door"); + + + } + private static void putFoldingDoor(String path) { + FOLDING_DOORS.put(CreateTFMG.asResource(path), + Couple.create(block(path + "/fold_left"), block(path + "/fold_right"))); + } + private static PartialModel block(String path) { + return new PartialModel(CreateTFMG.asResource("block/" + path)); + } + + public static void init() {} + + } \ No newline at end of file diff --git a/src/main/java/com/drmangotea/tfmg/registry/TFMGRegistrate.java b/src/main/java/com/drmangotea/tfmg/registry/TFMGRegistrate.java deleted file mode 100644 index 58072cba..00000000 --- a/src/main/java/com/drmangotea/tfmg/registry/TFMGRegistrate.java +++ /dev/null @@ -1,263 +0,0 @@ -package com.drmangotea.tfmg.registry; - - -import static com.simibubi.create.foundation.data.TagGen.pickaxeOnly; - -import java.util.function.BiConsumer; -import java.util.function.Consumer; -import java.util.function.Function; -import java.util.function.Supplier; - -import com.drmangotea.tfmg.CreateTFMG; -import com.simibubi.create.foundation.data.BlockStateGen; -import com.simibubi.create.foundation.data.CreateBlockEntityBuilder; -import com.simibubi.create.foundation.data.CreateEntityBuilder; -import com.simibubi.create.foundation.data.VirtualFluidBuilder; -import org.jetbrains.annotations.Nullable; - - -import com.simibubi.create.CreateClient; -import com.simibubi.create.content.decoration.encasing.CasingConnectivity; -import com.simibubi.create.content.fluids.VirtualFluid; -import com.simibubi.create.foundation.block.connected.CTModel; -import com.simibubi.create.foundation.block.connected.ConnectedTextureBehaviour; -import com.simibubi.create.foundation.item.TooltipModifier; -import com.simibubi.create.foundation.utility.RegisteredObjects; -import com.tterrag.registrate.AbstractRegistrate; -import com.tterrag.registrate.builders.BlockBuilder; -import com.tterrag.registrate.builders.BlockEntityBuilder.BlockEntityFactory; -import com.tterrag.registrate.builders.Builder; -import com.tterrag.registrate.builders.FluidBuilder; -import com.tterrag.registrate.util.entry.RegistryEntry; -import com.tterrag.registrate.util.nullness.NonNullConsumer; -import com.tterrag.registrate.util.nullness.NonNullFunction; -import com.tterrag.registrate.util.nullness.NonNullSupplier; - -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.core.Registry; -import net.minecraft.resources.ResourceKey; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.tags.BlockTags; -import net.minecraft.world.entity.Entity; -import net.minecraft.world.entity.EntityType; -import net.minecraft.world.entity.MobCategory; -import net.minecraft.world.item.Item; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.entity.BlockEntity; -import net.minecraft.world.level.block.state.BlockBehaviour.Properties; -import net.minecraftforge.api.distmarker.Dist; -import net.minecraftforge.api.distmarker.OnlyIn; -import net.minecraftforge.client.extensions.common.IClientFluidTypeExtensions; -import net.minecraftforge.eventbus.api.IEventBus; -import net.minecraftforge.fluids.FluidType; -import net.minecraftforge.fluids.ForgeFlowingFluid; -import net.minecraftforge.fml.DistExecutor; -import net.minecraftforge.registries.RegistryObject; - -public class TFMGRegistrate extends AbstractRegistrate { - @Nullable - protected Function currentTooltipModifierFactory; - - protected TFMGRegistrate(String modid) { - super(modid); - } - - public static TFMGRegistrate create(String modid) { - return new TFMGRegistrate(modid); - } - - public TFMGRegistrate setTooltipModifierFactory(@Nullable Function factory) { - currentTooltipModifierFactory = factory; - return self(); - } - - @Nullable - public Function getTooltipModifierFactory() { - return currentTooltipModifierFactory; - } - - @Override - public TFMGRegistrate registerEventListeners(IEventBus bus) { - return super.registerEventListeners(bus); - } - - @Override - protected RegistryEntry accept(String name, ResourceKey> type, - Builder builder, NonNullSupplier creator, - NonNullFunction, ? extends RegistryEntry> entryFactory) { - RegistryEntry entry = super.accept(name, type, builder, creator, entryFactory); - if (type.equals(Registry.ITEM_REGISTRY)) { - if (currentTooltipModifierFactory != null) { - TooltipModifier.REGISTRY.registerDeferred(entry.getId(), currentTooltipModifierFactory); - } - } - return entry; - } - - @Override - public CreateBlockEntityBuilder blockEntity(String name, - BlockEntityFactory factory) { - return blockEntity(self(), name, factory); - } - - @Override - public CreateBlockEntityBuilder blockEntity(P parent, String name, - BlockEntityFactory factory) { - return (CreateBlockEntityBuilder) entry(name, - (callback) -> CreateBlockEntityBuilder.create(this, parent, name, callback, factory)); - } - - @Override - public CreateEntityBuilder entity(String name, - EntityType.EntityFactory factory, MobCategory classification) { - return this.entity(self(), name, factory, classification); - } - - @Override - public CreateEntityBuilder entity(P parent, String name, - EntityType.EntityFactory factory, MobCategory classification) { - return (CreateEntityBuilder) this.entry(name, (callback) -> { - return CreateEntityBuilder.create(this, parent, name, callback, factory, classification); - }); - } - - /* Palettes */ - - public BlockBuilder paletteStoneBlock(String name, - NonNullFunction factory, NonNullSupplier propertiesFrom, boolean worldGenStone, - boolean hasNaturalVariants) { - BlockBuilder builder = super.block(name, factory).initialProperties(propertiesFrom) - .transform(pickaxeOnly()) - .blockstate(hasNaturalVariants ? BlockStateGen.naturalStoneTypeBlock(name) : (c, p) -> { - final String location = "block/palettes/stone_types/" + c.getName(); - p.simpleBlock(c.get(), p.models() - .cubeAll(c.getName(), p.modLoc(location))); - }) - .tag(BlockTags.DRIPSTONE_REPLACEABLE) - .tag(BlockTags.AZALEA_ROOT_REPLACEABLE) - .tag(BlockTags.MOSS_REPLACEABLE) - .tag(BlockTags.LUSH_GROUND_REPLACEABLE) - .item() - .model((c, p) -> p.cubeAll(c.getName(), - p.modLoc(hasNaturalVariants ? "block/palettes/stone_types/natural/" + name + "_1" - : "block/palettes/stone_types/" + c.getName()))) - .build(); - return builder; - } - - public BlockBuilder paletteStoneBlock(String name, NonNullSupplier propertiesFrom, - boolean worldGenStone, boolean hasNaturalVariants) { - return paletteStoneBlock(name, Block::new, propertiesFrom, worldGenStone, hasNaturalVariants); - } - - /* Fluids */ - - public FluidBuilder virtualFluid(String name, - FluidBuilder.FluidTypeFactory typeFactory, NonNullFunction factory) { - return entry(name, - c -> new VirtualFluidBuilder<>(self(), self(), name, c, CreateTFMG.asResource("fluid/" + name + "_still"), - CreateTFMG.asResource("fluid/" + name + "_flow"), typeFactory, factory)); - } - - public FluidBuilder virtualFluid(String name, - ResourceLocation still, ResourceLocation flow, FluidBuilder.FluidTypeFactory typeFactory, - NonNullFunction factory) { - return entry(name, c -> new VirtualFluidBuilder<>(self(), self(), name, c, still, flow, typeFactory, factory)); - } - - public FluidBuilder virtualFluid(String name) { - return entry(name, - c -> new VirtualFluidBuilder(self(), self(), name, c, - CreateTFMG.asResource("fluid/" + name + "_still"), CreateTFMG.asResource("fluid/" + name + "_flow"), - TFMGRegistrate::defaultFluidType, VirtualFluid::new)); - } - - public FluidBuilder virtualFluid(String name, ResourceLocation still, - ResourceLocation flow) { - return entry(name, c -> new VirtualFluidBuilder<>(self(), self(), name, c, still, flow, - TFMGRegistrate::defaultFluidType, VirtualFluid::new)); - } - - public FluidBuilder standardFluid(String name) { - return fluid(name, CreateTFMG.asResource("fluid/" + name + "_still"), CreateTFMG.asResource("fluid/" + name + "_flow")); - } - - public FluidBuilder standardFluid(String name, - FluidBuilder.FluidTypeFactory typeFactory) { - return fluid(name, CreateTFMG.asResource("fluid/" + name + "_still"), CreateTFMG.asResource("fluid/" + name + "_flow"), - typeFactory); - } - - public static FluidType defaultFluidType(FluidType.Properties properties, ResourceLocation stillTexture, - ResourceLocation flowingTexture) { - return new FluidType(properties) { - @Override - public void initializeClient(Consumer consumer) { - consumer.accept(new IClientFluidTypeExtensions() { - @Override - public ResourceLocation getStillTexture() { - return stillTexture; - } - - @Override - public ResourceLocation getFlowingTexture() { - return flowingTexture; - } - }); - } - }; - } - - /* Util */ - - public static NonNullConsumer casingConnectivity( - BiConsumer consumer) { - return entry -> onClient(() -> () -> registerCasingConnectivity(entry, consumer)); - } - - public static NonNullConsumer blockModel( - Supplier> func) { - return entry -> onClient(() -> () -> registerBlockModel(entry, func)); - } - - public static NonNullConsumer itemModel( - Supplier> func) { - return entry -> onClient(() -> () -> registerItemModel(entry, func)); - } - - public static NonNullConsumer connectedTextures( - Supplier behavior) { - return entry -> onClient(() -> () -> registerCTBehviour(entry, behavior)); - } - - protected static void onClient(Supplier toRun) { - DistExecutor.unsafeRunWhenOn(Dist.CLIENT, toRun); - } - - @OnlyIn(Dist.CLIENT) - private static void registerCasingConnectivity(T entry, - BiConsumer consumer) { - consumer.accept(entry, CreateClient.CASING_CONNECTIVITY); - } - - @OnlyIn(Dist.CLIENT) - private static void registerBlockModel(Block entry, - Supplier> func) { - CreateClient.MODEL_SWAPPER.getCustomBlockModels() - .register(RegisteredObjects.getKeyOrThrow(entry), func.get()); - } - - @OnlyIn(Dist.CLIENT) - private static void registerItemModel(Item entry, - Supplier> func) { - CreateClient.MODEL_SWAPPER.getCustomItemModels() - .register(RegisteredObjects.getKeyOrThrow(entry), func.get()); - } - - @OnlyIn(Dist.CLIENT) - private static void registerCTBehviour(Block entry, Supplier behaviorSupplier) { - ConnectedTextureBehaviour behavior = behaviorSupplier.get(); - CreateClient.MODEL_SWAPPER.getCustomBlockModels() - .register(RegisteredObjects.getKeyOrThrow(entry), model -> new CTModel(model, behavior)); - } -} diff --git a/src/main/resources/assets/tfmg/blockstates/blue_fire.json b/src/main/resources/assets/tfmg/blockstates/blue_fire.json index d1bfe7d8..45424512 100644 --- a/src/main/resources/assets/tfmg/blockstates/blue_fire.json +++ b/src/main/resources/assets/tfmg/blockstates/blue_fire.json @@ -3,10 +3,10 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_floor0" + "model": "tfmg:block/fire/blue_fire_floor0" }, { - "model": "tfmg:block/blue_fire_floor1" + "model": "tfmg:block/fire/blue_fire_floor1" } ], "when": { @@ -20,16 +20,16 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_side0" + "model": "tfmg:block/fire/blue_fire_side0" }, { - "model": "tfmg:block/blue_fire_side1" + "model": "tfmg:block/fire/blue_fire_side1" }, { - "model": "tfmg:block/blue_fire_side_alt0" + "model": "tfmg:block/fire/blue_fire_side_alt0" }, { - "model": "tfmg:block/blue_fire_side_alt1" + "model": "tfmg:block/fire/blue_fire_side_alt1" } ], "when": { @@ -50,19 +50,19 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_side0", + "model": "tfmg:block/fire/blue_fire_side0", "y": 90 }, { - "model": "tfmg:block/blue_fire_side1", + "model": "tfmg:block/fire/blue_fire_side1", "y": 90 }, { - "model": "tfmg:block/blue_fire_side_alt0", + "model": "tfmg:block/fire/blue_fire_side_alt0", "y": 90 }, { - "model": "tfmg:block/blue_fire_side_alt1", + "model": "tfmg:block/fire/blue_fire_side_alt1", "y": 90 } ], @@ -84,19 +84,19 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_side0", + "model": "tfmg:block/fire/blue_fire_side0", "y": 180 }, { - "model": "tfmg:block/blue_fire_side1", + "model": "tfmg:block/fire/blue_fire_side1", "y": 180 }, { - "model": "tfmg:block/blue_fire_side_alt0", + "model": "tfmg:block/fire/blue_fire_side_alt0", "y": 180 }, { - "model": "tfmg:block/blue_fire_side_alt1", + "model": "tfmg:block/fire/blue_fire_side_alt1", "y": 180 } ], @@ -118,19 +118,19 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_side0", + "model": "tfmg:block/fire/blue_fire_side0", "y": 270 }, { - "model": "tfmg:block/blue_fire_side1", + "model": "tfmg:block/fire/blue_fire_side1", "y": 270 }, { - "model": "tfmg:block/blue_fire_side_alt0", + "model": "tfmg:block/fire/blue_fire_side_alt0", "y": 270 }, { - "model": "tfmg:block/blue_fire_side_alt1", + "model": "tfmg:block/fire/blue_fire_side_alt1", "y": 270 } ], @@ -152,16 +152,16 @@ { "apply": [ { - "model": "tfmg:block/blue_fire_up0" + "model": "tfmg:block/fire/blue_fire_up0" }, { - "model": "tfmg:block/blue_fire_up1" + "model": "tfmg:block/fire/blue_fire_up1" }, { - "model": "tfmg:block/blue_fire_up_alt0" + "model": "tfmg:block/fire/blue_fire_up_alt0" }, { - "model": "tfmg:block/blue_fire_up_alt1" + "model": "tfmg:block/fire/blue_fire_up_alt1" } ], "when": { diff --git a/src/main/resources/assets/tfmg/blockstates/green_fire.json b/src/main/resources/assets/tfmg/blockstates/green_fire.json index 59812148..1b1f8f06 100644 --- a/src/main/resources/assets/tfmg/blockstates/green_fire.json +++ b/src/main/resources/assets/tfmg/blockstates/green_fire.json @@ -3,10 +3,10 @@ { "apply": [ { - "model": "tfmg:block/green_fire_floor0" + "model": "tfmg:block/fire/green_fire_floor0" }, { - "model": "tfmg:block/green_fire_floor1" + "model": "tfmg:block/fire/green_fire_floor1" } ], "when": { @@ -20,16 +20,16 @@ { "apply": [ { - "model": "tfmg:block/green_fire_side0" + "model": "tfmg:block/fire/green_fire_side0" }, { - "model": "tfmg:block/green_fire_side1" + "model": "tfmg:block/fire/green_fire_side1" }, { - "model": "tfmg:block/green_fire_side_alt0" + "model": "tfmg:block/fire/green_fire_side_alt0" }, { - "model": "tfmg:block/green_fire_side_alt1" + "model": "tfmg:block/fire/green_fire_side_alt1" } ], "when": { @@ -50,19 +50,19 @@ { "apply": [ { - "model": "tfmg:block/green_fire_side0", + "model": "tfmg:block/fire/green_fire_side0", "y": 90 }, { - "model": "tfmg:block/green_fire_side1", + "model": "tfmg:block/fire/green_fire_side1", "y": 90 }, { - "model": "tfmg:block/green_fire_side_alt0", + "model": "tfmg:block/fire/green_fire_side_alt0", "y": 90 }, { - "model": "tfmg:block/green_fire_side_alt1", + "model": "tfmg:block/fire/green_fire_side_alt1", "y": 90 } ], @@ -84,19 +84,19 @@ { "apply": [ { - "model": "tfmg:block/green_fire_side0", + "model": "tfmg:block/fire/green_fire_side0", "y": 180 }, { - "model": "tfmg:block/green_fire_side1", + "model": "tfmg:block/fire/green_fire_side1", "y": 180 }, { - "model": "tfmg:block/green_fire_side_alt0", + "model": "tfmg:block/fire/green_fire_side_alt0", "y": 180 }, { - "model": "tfmg:block/green_fire_side_alt1", + "model": "tfmg:block/fire/green_fire_side_alt1", "y": 180 } ], @@ -118,19 +118,19 @@ { "apply": [ { - "model": "tfmg:block/green_fire_side0", + "model": "tfmg:block/fire/green_fire_side0", "y": 270 }, { - "model": "tfmg:block/green_fire_side1", + "model": "tfmg:block/fire/green_fire_side1", "y": 270 }, { - "model": "tfmg:block/green_fire_side_alt0", + "model": "tfmg:block/fire/green_fire_side_alt0", "y": 270 }, { - "model": "tfmg:block/green_fire_side_alt1", + "model": "tfmg:block/fire/green_fire_side_alt1", "y": 270 } ], @@ -152,16 +152,16 @@ { "apply": [ { - "model": "tfmg:block/green_fire_up0" + "model": "tfmg:block/fire/green_fire_up0" }, { - "model": "tfmg:block/green_fire_up1" + "model": "tfmg:block/fire/green_fire_up1" }, { - "model": "tfmg:block/green_fire_up_alt0" + "model": "tfmg:block/fire/green_fire_up_alt0" }, { - "model": "tfmg:block/green_fire_up_alt1" + "model": "tfmg:block/fire/green_fire_up_alt1" } ], "when": { diff --git a/src/main/resources/assets/tfmg/lang/default/interface.json b/src/main/resources/assets/tfmg/lang/default/interface.json new file mode 100644 index 00000000..a2c87fad --- /dev/null +++ b/src/main/resources/assets/tfmg/lang/default/interface.json @@ -0,0 +1,4 @@ +{ + "itemGroup.tfmg.base": "Create: The Factory Must Grow", + "itemGroup.tfmg.concrete": "Create: TFMG's Concrete" +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_floor0.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_floor0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_floor0.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_floor0.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_floor1.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_floor1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_floor1.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_floor1.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_side0.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_side0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_side0.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_side0.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_side1.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_side1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_side1.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_side1.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_side_alt0.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_side_alt0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_side_alt0.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_side_alt0.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_side_alt1.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_side_alt1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_side_alt1.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_side_alt1.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_up0.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_up0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_up0.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_up0.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_up1.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_up1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_up1.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_up1.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_up_alt0.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_up_alt0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_up_alt0.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_up_alt0.json diff --git a/src/main/resources/assets/tfmg/models/block/blue_fire_up_alt1.json b/src/main/resources/assets/tfmg/models/block/fire/blue_fire_up_alt1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/blue_fire_up_alt1.json rename to src/main/resources/assets/tfmg/models/block/fire/blue_fire_up_alt1.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_floor0.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_floor0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_floor0.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_floor0.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_floor1.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_floor1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_floor1.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_floor1.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_side0.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_side0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_side0.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_side0.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_side1.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_side1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_side1.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_side1.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_side_alt0.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_side_alt0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_side_alt0.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_side_alt0.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_side_alt1.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_side_alt1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_side_alt1.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_side_alt1.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_up0.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_up0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_up0.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_up0.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_up1.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_up1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_up1.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_up1.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_up_alt0.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_up_alt0.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_up_alt0.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_up_alt0.json diff --git a/src/main/resources/assets/tfmg/models/block/green_fire_up_alt1.json b/src/main/resources/assets/tfmg/models/block/fire/green_fire_up_alt1.json similarity index 100% rename from src/main/resources/assets/tfmg/models/block/green_fire_up_alt1.json rename to src/main/resources/assets/tfmg/models/block/fire/green_fire_up_alt1.json diff --git a/src/main/resources/assets/tfmg/models/block/formwork_block/block_base.json b/src/main/resources/assets/tfmg/models/block/formwork_block/block_base.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/formwork_block/block_base.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/formwork_block/block_bottom.json b/src/main/resources/assets/tfmg/models/block/formwork_block/block_bottom.json new file mode 100644 index 00000000..c798dee0 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/formwork_block/block_bottom.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/formwork_bottom", + "particle": "tfmg:block/formwork_bottom" + }, + "elements": [ + { + "from": [0, 0, 0], + "to": [16, 1, 16], + "faces": { + "north": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "east": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "south": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "west": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "up": {"uv": [0, 0, 16, 16], "texture": "#0"}, + "down": {"uv": [0, 0, 16, 16], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/formwork_block/block_side.json b/src/main/resources/assets/tfmg/models/block/formwork_block/block_side.json new file mode 100644 index 00000000..fd17c855 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/formwork_block/block_side.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/formwork_side", + "particle": "tfmg:block/formwork_side" + }, + "elements": [ + { + "from": [0, 0, -0.1], + "to": [16, 16.001, 0.9], + "faces": { + "north": {"uv": [0, 0, 16, 16], "texture": "#0"}, + "east": {"uv": [0, 0, 1, 16], "texture": "#0"}, + "south": {"uv": [0, 0, 16, 16], "texture": "#0"}, + "west": {"uv": [0, 0, 1, 16], "texture": "#0"}, + "up": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "down": {"uv": [0, 0, 16, 1], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/formwork_block/formwork_bottom.json b/src/main/resources/assets/tfmg/models/block/formwork_block/formwork_bottom.json new file mode 100644 index 00000000..34fc6fdf --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/formwork_block/formwork_bottom.json @@ -0,0 +1,21 @@ +{ + "credit": "Made with Blockbench", + "textures": { + "0": "tfmg:block/formwork_bottom", + "particle": "tfmg:block/formwork_bottom" + }, + "elements": [ + { + "from": [1, 0, 1], + "to": [15, 1, 15], + "faces": { + "north": {"uv": [0, 0, 14, 1], "texture": "#0"}, + "east": {"uv": [0, 0, 14, 1], "texture": "#0"}, + "south": {"uv": [0, 0, 14, 1], "texture": "#0"}, + "west": {"uv": [0, 0, 14, 1], "texture": "#0"}, + "up": {"uv": [1, 1, 15, 15], "texture": "#0"}, + "down": {"uv": [0, 0, 14, 14], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/models/block/formwork_block/item.json b/src/main/resources/assets/tfmg/models/block/formwork_block/item.json new file mode 100644 index 00000000..a3096241 --- /dev/null +++ b/src/main/resources/assets/tfmg/models/block/formwork_block/item.json @@ -0,0 +1,75 @@ +{ + "credit": "Made with Blockbench", + "parent": "minecraft:block/block", + "textures": { + "0": "tfmg:block/formwork_bottom", + "1": "tfmg:block/formwork_side", + "particle": "tfmg:block/formwork_bottom" + }, + "elements": [ + { + "from": [1, 1, 0], + "to": [16, 16, 1], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 0, 8]}, + "faces": { + "north": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "east": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "south": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "west": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "up": {"uv": [0, 0, 15, 1], "texture": "#1"}, + "down": {"uv": [0, 0, 15, 1], "texture": "#1"} + } + }, + { + "from": [0, 1, 0], + "to": [1, 16, 15], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 0, 8]}, + "faces": { + "north": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "east": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "south": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "west": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "up": {"uv": [0, 0, 15, 1], "rotation": 270, "texture": "#1"}, + "down": {"uv": [0, 0, 15, 1], "rotation": 90, "texture": "#1"} + } + }, + { + "from": [0, 1, 15], + "to": [15, 16, 16], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 0, 8]}, + "faces": { + "north": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "east": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "south": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "west": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "up": {"uv": [0, 0, 15, 1], "rotation": 180, "texture": "#1"}, + "down": {"uv": [0, 0, 15, 1], "rotation": 180, "texture": "#1"} + } + }, + { + "from": [15, 1, 1], + "to": [16, 16, 16], + "rotation": {"angle": 0, "axis": "y", "origin": [8, 0, 8]}, + "faces": { + "north": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "east": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "south": {"uv": [0, 0, 1, 15], "texture": "#1"}, + "west": {"uv": [0, 0, 15, 15], "texture": "#1"}, + "up": {"uv": [0, 0, 15, 1], "rotation": 90, "texture": "#1"}, + "down": {"uv": [0, 0, 15, 1], "rotation": 270, "texture": "#1"} + } + }, + { + "from": [0, 0, 0], + "to": [16, 1, 16], + "faces": { + "north": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "east": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "south": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "west": {"uv": [0, 0, 16, 1], "texture": "#0"}, + "up": {"uv": [0, 0, 16, 16], "texture": "#0"}, + "down": {"uv": [0, 0, 16, 16], "texture": "#0"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/tfmg/textures/block/formwork_bottom.png b/src/main/resources/assets/tfmg/textures/block/formwork_bottom.png new file mode 100644 index 00000000..f7159bff Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/formwork_bottom.png differ diff --git a/src/main/resources/assets/tfmg/textures/block/formwork_side.png b/src/main/resources/assets/tfmg/textures/block/formwork_side.png new file mode 100644 index 00000000..3273390a Binary files /dev/null and b/src/main/resources/assets/tfmg/textures/block/formwork_side.png differ