java.lang.Object
com.minecolonies.core.network.messages.server.AbstractColonyServerMessage
com.minecolonies.core.network.messages.server.colony.InteractionClose
All Implemented Interfaces:
IMessage

public class InteractionClose extends AbstractColonyServerMessage
Message to trigger a response handler close on the server side.
  • Constructor Details

    • InteractionClose

      public InteractionClose()
      Empty public constructor.
    • InteractionClose

      public InteractionClose(int colonyId, int citizenId, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> dimension, @NotNull @NotNull net.minecraft.network.chat.Component key)
      Trigger the server response handler.
      Parameters:
      colonyId - the colony id.
      citizenId - the citizen id.
      dimension - the dimension the colony and citizen are in.
      key - the key of the handler.
  • Method Details

    • fromBytesOverride

      public void fromBytesOverride(@NotNull @NotNull net.minecraft.network.FriendlyByteBuf buf)
      Transformation from a byteStream to the variables.
      Specified by:
      fromBytesOverride in class AbstractColonyServerMessage
      Parameters:
      buf - the used byteBuffer.
    • toBytesOverride

      public void toBytesOverride(@NotNull @NotNull net.minecraft.network.FriendlyByteBuf buf)
      Transformation to a byteStream.
      Specified by:
      toBytesOverride in class AbstractColonyServerMessage
      Parameters:
      buf - the used byteBuffer.
    • onExecute

      protected void onExecute(net.minecraftforge.network.NetworkEvent.Context ctxIn, boolean isLogicalServer, IColony colony)
      Specified by:
      onExecute in class AbstractColonyServerMessage