engine fixes

This commit is contained in:
DrMangoTea
2023-10-25 15:02:32 +02:00
parent 795426b7d1
commit a534e865f1
3 changed files with 11 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
package com.drmangotea.tfmg.blocks.engines.small;
import com.drmangotea.createindustry.content.oil.exhaust.ExhaustBlock;
import com.drmangotea.createindustry.registry.CIFluids;
import com.drmangotea.tfmg.registry.TFMGFluids;
import com.simibubi.create.content.equipment.goggles.IHaveGoggleInformation;
import com.simibubi.create.foundation.blockEntity.SmartBlockEntity;
import com.simibubi.create.foundation.blockEntity.behaviour.BlockEntityBehaviour;
@@ -13,6 +13,7 @@ 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.DirectionalBlock;
import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraft.world.level.block.state.BlockState;
@@ -133,7 +134,7 @@ import java.util.Optional;
return new SmartFluidTank(1000, this::onFluidStackChanged){
@Override
public boolean isFluidValid(FluidStack stack) {
return stack.getFluid().isSame(CIFluids.CARBON_DIOXIDE.getSource());
return stack.getFluid().isSame(TFMGFluids.CARBON_DIOXIDE.getSource());
}
};
}
@@ -142,7 +143,7 @@ import java.util.Optional;
sendData();
}
public BlockEntity getFrontPart(){
Direction direction = this.getBlockState().getValue(ExhaustBlock.FACING);
Direction direction = this.getBlockState().getValue(DirectionalBlock.FACING);
if(direction == Direction.UP)
return level.getBlockEntity(this.getBlockPos().above());

View File

@@ -1,7 +1,8 @@
package com.drmangotea.tfmg.blocks.engines.small;
import com.drmangotea.createindustry.registry.CIShapes;
import com.drmangotea.tfmg.registry.TFMGShapes;
import com.simibubi.create.content.kinetics.base.DirectionalKineticBlock;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
@@ -34,9 +35,9 @@ abstract public class EngineBlock extends DirectionalKineticBlock {
public VoxelShape getShape(BlockState pState, BlockGetter worldIn, BlockPos pos, CollisionContext context) {
if(pState.getValue(FACING).getAxis()==Axis.Y) {
return CIShapes.ENGINE_VERTICAL.get(pState.getValue(FACING));
return TFMGShapes.ENGINE_VERTICAL.get(pState.getValue(FACING));
}else
return CIShapes.ENGINE.get(pState.getValue(FACING));
return TFMGShapes.ENGINE.get(pState.getValue(FACING));
}

View File

@@ -1,6 +1,7 @@
package com.drmangotea.tfmg.blocks.engines.small.gasoline;
import com.drmangotea.createindustry.content.blocks.engines.EngineBlock;
import com.drmangotea.tfmg.blocks.engines.small.EngineBlock;
import com.simibubi.create.foundation.data.AssetLookup;
import com.simibubi.create.foundation.data.SpecialBlockStateGen;
import com.tterrag.registrate.providers.DataGenContext;