From 9fee35c065e197199f57ef1df31ac303e94d1d50 Mon Sep 17 00:00:00 2001 From: HoleFish <48403212+HoleFish@users.noreply.github.com> Date: Sat, 31 Aug 2024 01:48:23 +0800 Subject: Add duration since last shutdown (#2977) * machine message * fix & prass channel * machine message * fix & prass channel * fix machines that dont use regular onPostTick * follow error fixes and fix hatch check * oops * sa --------- Co-authored-by: Martin Robertz Co-authored-by: boubou19 --- .../api/recipe/check/CheckRecipeResult.java | 34 ++-------------------- 1 file changed, 2 insertions(+), 32 deletions(-) (limited to 'src/main/java/gregtech/api/recipe/check/CheckRecipeResult.java') diff --git a/src/main/java/gregtech/api/recipe/check/CheckRecipeResult.java b/src/main/java/gregtech/api/recipe/check/CheckRecipeResult.java index 8af5c58f5e..60436b9c3e 100644 --- a/src/main/java/gregtech/api/recipe/check/CheckRecipeResult.java +++ b/src/main/java/gregtech/api/recipe/check/CheckRecipeResult.java @@ -1,8 +1,6 @@ package gregtech.api.recipe.check; -import javax.annotation.Nonnull; - -import net.minecraft.network.PacketBuffer; +import gregtech.api.util.IMachineMessage; /** * Class to indicate the result of recipe check in the machine. It doesn't need to be actual result of recipemap check, @@ -10,41 +8,13 @@ import net.minecraft.network.PacketBuffer; *

* Sample instance must be registered to {@link CheckRecipeResultRegistry}. */ -public interface CheckRecipeResult { - - /** - * @return Unique registry ID - */ - @Nonnull - String getID(); +public interface CheckRecipeResult extends IMachineMessage { /** * @return If recipe check is successful */ boolean wasSuccessful(); - /** - * @return Actual text to show on client GUI - */ - @Nonnull - String getDisplayString(); - - /** - * Create new instance to receive packet. - */ - @Nonnull - CheckRecipeResult newInstance(); - - /** - * Encode value to sync. - */ - void encode(@Nonnull PacketBuffer buffer); - - /** - * Decode synced value. - */ - void decode(PacketBuffer buffer); - /** * @return If this message should stay on GUI when the machine is shut down. */ -- cgit