-
Notifications
You must be signed in to change notification settings - Fork 112
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: IO Config with wrench + GUI not implemented after machine rewrite
Fixes: GH-944
- Loading branch information
Showing
5 changed files
with
87 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
enderio-machines/src/main/java/com/enderio/machines/common/network/CycleIOConfigPacket.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package com.enderio.machines.common.network; | ||
|
||
import com.enderio.base.api.EnderIO; | ||
import io.netty.buffer.ByteBuf; | ||
import net.minecraft.core.BlockPos; | ||
import net.minecraft.core.Direction; | ||
import net.minecraft.network.codec.StreamCodec; | ||
import net.minecraft.network.protocol.common.custom.CustomPacketPayload; | ||
|
||
public record CycleIOConfigPacket(BlockPos pos, Direction side) implements CustomPacketPayload { | ||
|
||
public static final Type<CycleIOConfigPacket> TYPE = new Type<>(EnderIO.loc("cycle_io_config")); | ||
|
||
public static StreamCodec<ByteBuf, CycleIOConfigPacket> STREAM_CODEC = StreamCodec.composite(BlockPos.STREAM_CODEC, | ||
CycleIOConfigPacket::pos, Direction.STREAM_CODEC, CycleIOConfigPacket::side, CycleIOConfigPacket::new); | ||
|
||
@Override | ||
public Type<? extends CustomPacketPayload> type() { | ||
return TYPE; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters