类 CustomPayloadEvent.Context

java.lang.Object
net.minecraftforge.event.network.CustomPayloadEvent.Context
封闭类:
CustomPayloadEvent

public static class CustomPayloadEvent.Context extends Object
Context for CustomPayloadEvent
  • 字段详细资料

    • connection

      private final Connection connection
      The Connection for this message.
    • client

      private final boolean client
    • packetHandled

      private boolean packetHandled
  • 构造器详细资料

  • 方法详细资料

    • isClientSide

      public boolean isClientSide()
    • isServerSide

      public boolean isServerSide()
    • getConnection

      public Connection getConnection()
    • attr

      public <T> io.netty.util.Attribute<T> attr(io.netty.util.AttributeKey<T> key)
    • setPacketHandled

      public void setPacketHandled(boolean packetHandled)
    • getPacketHandled

      public boolean getPacketHandled()
    • enqueueWork

      public CompletableFuture<Void> enqueueWork(Runnable runnable)
    • getSender

      @Nullable public @Nullable ServerPlayer getSender()
      When available, gets the sender for packets that are sent from a client to the server.