diff --git a/build.gradle b/build.gradle index 477a323d..0fe9feb1 100644 --- a/build.gradle +++ b/build.gradle @@ -143,7 +143,7 @@ dependencies { implementation project(path: ":catalyst:effects",configuration: "namedElements") //implementation project(path: ":dragonfly",configuration: "namedElements") - modImplementation "DragonFly:dragonfly:${project.dragonfly_version}" + modImplementation files("libs/dragonfly-1.4.7-7.1-test.2.jar") //"DragonFly:dragonfly:${project.dragonfly_version}" modImplementation "BTWaila:btwaila:${project.btwaila_version}" modImplementation "TerrainAPI:terrainapi:${project.terrain_api_version}" //modImplementation "retrostorage:retrostorage:1.3.0" diff --git a/gradle.properties b/gradle.properties index 1d9d5dd8..ee3f7135 100644 --- a/gradle.properties +++ b/gradle.properties @@ -9,7 +9,7 @@ loader_version=0.15.6-babric.4-bta # Mods halplibe_version=3.5.1 modmenu_version=2.0.4 -dragonfly_version=1.4.4-7.1 +dragonfly_version=1.4.6-7.1 btwaila_version=1.0.9-7.1 terrain_api_version=1.4.2-7.1 diff --git a/libs/dragonfly-1.4.7-7.1-test.2.jar b/libs/dragonfly-1.4.7-7.1-test.2.jar new file mode 100644 index 00000000..0bc6b848 Binary files /dev/null and b/libs/dragonfly-1.4.7-7.1-test.2.jar differ diff --git a/src/main/java/sunsetsatellite/signalindustries/SignalIndustries.java b/src/main/java/sunsetsatellite/signalindustries/SignalIndustries.java index 0420db1c..4163290b 100644 --- a/src/main/java/sunsetsatellite/signalindustries/SignalIndustries.java +++ b/src/main/java/sunsetsatellite/signalindustries/SignalIndustries.java @@ -2,6 +2,7 @@ import net.fabricmc.api.ModInitializer; +import net.fabricmc.loader.api.FabricLoader; import net.minecraft.client.Minecraft; import net.minecraft.client.entity.fx.EntityFX; import net.minecraft.client.gui.Gui; @@ -1257,6 +1258,7 @@ public void onInitialize() { } public SignalIndustries(){ + //RecipeFIleLoader.load("/assets/signalindustries/recipes/recipes.txt",mapOf(new String[]{"SignalIndustries"},new String[]{"sunsetsatellite.signalindustries.SignalIndustries"})); BlockModelDispatcher.getInstance().addDispatch(dilithiumRail,new BlockModelRenderBlocks(9)); BlockModelDispatcher.getInstance().addDispatch(energyStill,new BlockModelRenderBlocks(4)); diff --git a/src/main/java/sunsetsatellite/signalindustries/blocks/BlockFilter.java b/src/main/java/sunsetsatellite/signalindustries/blocks/BlockFilter.java index 2b0d2854..77c0b813 100644 --- a/src/main/java/sunsetsatellite/signalindustries/blocks/BlockFilter.java +++ b/src/main/java/sunsetsatellite/signalindustries/blocks/BlockFilter.java @@ -4,8 +4,10 @@ import net.minecraft.core.block.entity.TileEntityChest; import net.minecraft.core.block.material.Material; import net.minecraft.core.entity.EntityItem; +import net.minecraft.core.entity.EntityLiving; import net.minecraft.core.entity.player.EntityPlayer; import net.minecraft.core.item.ItemStack; +import net.minecraft.core.util.helper.Side; import net.minecraft.core.world.World; import sunsetsatellite.catalyst.core.util.Direction; import sunsetsatellite.catalyst.fluids.impl.tiles.TileEntityFluidPipe; @@ -76,6 +78,18 @@ public boolean blockActivated(World world, int i, int j, int k, EntityPlayer ent } } + @Override + public void setDefaultDirection(World world, int i, int j, int k) { + if (!world.isClientSide) { + world.setBlockMetadataWithNotify(i, j, k, 0); + } + } + + @Override + public void onBlockPlaced(World world, int x, int y, int z, Side side, EntityLiving entity, double sideHeight) { + world.setBlockMetadataWithNotify(x, y, z, 0); + } + @Override protected TileEntity getNewBlockEntity() { return new TileEntityFilter(); diff --git a/src/main/java/sunsetsatellite/signalindustries/blocks/states/ItemConduitStateInterpreter.java b/src/main/java/sunsetsatellite/signalindustries/blocks/states/ItemConduitStateInterpreter.java index e54bff32..f35ef2d6 100644 --- a/src/main/java/sunsetsatellite/signalindustries/blocks/states/ItemConduitStateInterpreter.java +++ b/src/main/java/sunsetsatellite/signalindustries/blocks/states/ItemConduitStateInterpreter.java @@ -21,6 +21,9 @@ public class ItemConduitStateInterpreter extends MetaStateInterpreter { @Override public HashMap getStateMap(WorldSource worldSource, int i, int j, int k, Block block, int meta) { HashMap states = new HashMap<>(); + /*if(!(worldSource.getBlockTileEntity(i,j,k) instanceof TileEntityItemConduit)){ + return states; + }*/ TileEntityItemConduit tile = (TileEntityItemConduit) worldSource.getBlockTileEntity(i,j,k); for (Direction direction : Direction.values()) { boolean show = false; diff --git a/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityFilter.java b/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityFilter.java index f35d072f..74eacb5d 100644 --- a/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityFilter.java +++ b/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityFilter.java @@ -100,11 +100,11 @@ public void readFromNBT(CompoundTag tag) { public enum FilterSide { RED(Direction.Y_POS), - GREEN(Direction.Z_NEG), - BLUE(Direction.X_NEG), + GREEN(Direction.Z_POS), + BLUE(Direction.X_POS), CYAN(Direction.Y_NEG), - MAGENTA(Direction.Z_POS), - YELLOW(Direction.X_POS); + MAGENTA(Direction.Z_NEG), + YELLOW(Direction.X_NEG); private final Direction direction; diff --git a/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityItemConduit.java b/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityItemConduit.java index 28730472..643a5311 100644 --- a/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityItemConduit.java +++ b/src/main/java/sunsetsatellite/signalindustries/inventories/TileEntityItemConduit.java @@ -175,6 +175,9 @@ public void extractItem(){ } } } + if(stack.stackSize <= 0){ + inv.setInventorySlotContents(slot,null); + } return; } if(exit == null){ diff --git a/src/main/resources/assets/signalindustries/block/item_conduit_basic_sensor_off.png b/src/main/resources/assets/signalindustries/block/item_conduit_basic_sensor_off.png new file mode 100644 index 00000000..bf37cc37 Binary files /dev/null and b/src/main/resources/assets/signalindustries/block/item_conduit_basic_sensor_off.png differ