Interface AbstractPacket<T extends AbstractPacket<T>>

All Superinterfaces:
net.minecraft.network.protocol.common.custom.CustomPacketPayload
All Known Implementing Classes:
AreaPacket, BundleHashPacket, ClientBoundFileContentPacket, ClientBoundFileListPacket, CutsceneCommandPacket, CutscenePacket, SavedDataSyncPacket, ScreenEffectPacket, ServerBoundChangeWeatherPacket, ServerBoundRequestFileContentPacket, ServerBoundRequestFileListPacket, ServerBoundSaveFilePacket, ServerBoundSetTimePacket, ServerBoundSpawnEntityPacket, ServerBoundTeleportPacket, TestPacket, WaypointPacket

public interface AbstractPacket<T extends AbstractPacket<T>> extends net.minecraft.network.protocol.common.custom.CustomPacketPayload
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final record 
     

    Nested classes/interfaces inherited from interface net.minecraft.network.protocol.common.custom.CustomPacketPayload

    net.minecraft.network.protocol.common.custom.CustomPacketPayload.FallbackProvider<B>, net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T>, net.minecraft.network.protocol.common.custom.CustomPacketPayload.TypeAndCodec<B,T>
  • Method Summary

    Modifier and Type
    Method
    Description
    static <T extends net.minecraft.network.protocol.common.custom.CustomPacketPayload>
    net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T>
    createType(net.minecraft.resources.Identifier id)
     
     
    net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf, T>
     
    net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T>
     
    default void
    handleClient(net.neoforged.neoforge.network.handling.IPayloadContext ctx)
     
    default void
    handleServer(net.neoforged.neoforge.network.handling.IPayloadContext ctx)
     
    default net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<? extends net.minecraft.network.protocol.common.custom.CustomPacketPayload>
     

    Methods inherited from interface net.minecraft.network.protocol.common.custom.CustomPacketPayload

    toVanillaClientbound, toVanillaServerbound
  • Method Details

    • createType

      static <T extends net.minecraft.network.protocol.common.custom.CustomPacketPayload> net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T> createType(net.minecraft.resources.Identifier id)
    • type

      default net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<? extends net.minecraft.network.protocol.common.custom.CustomPacketPayload> type()
      Specified by:
      type in interface net.minecraft.network.protocol.common.custom.CustomPacketPayload
    • getType

      net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T> getType()
    • getBoundTo

      PacketBounds getBoundTo()
    • getCodec

      net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf, T> getCodec()
    • handleClient

      default void handleClient(net.neoforged.neoforge.network.handling.IPayloadContext ctx)
    • handleServer

      default void handleServer(net.neoforged.neoforge.network.handling.IPayloadContext ctx)