Uses of Interface
net.minecraft.network.protocol.common.custom.CustomPacketPayload
Packages that use CustomPacketPayload
Package
Description
-
Uses of CustomPacketPayload in net.minecraft.client.multiplayer
Methods in net.minecraft.client.multiplayer with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionprotected abstract voidClientCommonPacketListenerImpl.handleCustomPayload(CustomPacketPayload p_295776_) protected voidClientConfigurationPacketListenerImpl.handleCustomPayload(CustomPacketPayload p_295411_) voidClientPacketListener.handleCustomPayload(CustomPacketPayload p_295851_) private voidClientConfigurationPacketListenerImpl.handleUnknownCustomPayload(CustomPacketPayload p_296412_) private voidClientPacketListener.handleUnknownCustomPayload(CustomPacketPayload p_294389_) -
Uses of CustomPacketPayload in net.minecraft.network.protocol.common
Fields in net.minecraft.network.protocol.common declared as CustomPacketPayloadModifier and TypeFieldDescriptionprivate final CustomPacketPayloadClientboundCustomPayloadPacket.payloadThe field for thepayloadrecord component.private final CustomPacketPayloadServerboundCustomPayloadPacket.payloadThe field for thepayloadrecord component.Methods in net.minecraft.network.protocol.common that return CustomPacketPayloadModifier and TypeMethodDescriptionClientboundCustomPayloadPacket.payload()Returns the value of thepayloadrecord component.ServerboundCustomPayloadPacket.payload()Returns the value of thepayloadrecord component.Constructors in net.minecraft.network.protocol.common with parameters of type CustomPacketPayloadModifierConstructorDescriptionCreates an instance of aClientboundCustomPayloadPacketrecord class.Creates an instance of aServerboundCustomPayloadPacketrecord class. -
Uses of CustomPacketPayload in net.minecraft.network.protocol.common.custom
Classes in net.minecraft.network.protocol.common.custom with type parameters of type CustomPacketPayloadModifier and TypeClassDescriptionstatic final recordCustomPacketPayload.Type<T extends CustomPacketPayload>static final recordCustomPacketPayload.TypeAndCodec<B extends FriendlyByteBuf,T extends CustomPacketPayload> Classes in net.minecraft.network.protocol.common.custom that implement CustomPacketPayloadModifier and TypeClassDescriptionfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordfinal recordMethods in net.minecraft.network.protocol.common.custom with type parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionstatic <B extends io.netty.buffer.ByteBuf,T extends CustomPacketPayload>
StreamCodec<B, T> CustomPacketPayload.codec(StreamMemberEncoder<B, T> p_319960_, StreamDecoder<B, T> p_320047_) static <T extends CustomPacketPayload>
CustomPacketPayload.Type<T> CustomPacketPayload.createType(String p_319908_) Methods in net.minecraft.network.protocol.common.custom that return types with arguments of type CustomPacketPayloadModifier and TypeMethodDescriptionstatic <B extends FriendlyByteBuf>
StreamCodec<B, CustomPacketPayload> CustomPacketPayload.codec(CustomPacketPayload.FallbackProvider<B> p_319839_, List<CustomPacketPayload.TypeAndCodec<? super B, ?>> p_320495_, ConnectionProtocol protocol, PacketFlow packetFlow) StreamCodec<B, ? extends CustomPacketPayload> CustomPacketPayload.FallbackProvider.create(ResourceLocation p_320236_) CustomPacketPayload.Type<? extends CustomPacketPayload> CustomPacketPayload.type() -
Uses of CustomPacketPayload in net.minecraft.network.protocol.game
Methods in net.minecraft.network.protocol.game with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionprivate static voidDebugPackets.sendPacketToAllPlayers(ServerLevel p_133692_, CustomPacketPayload p_296119_) -
Uses of CustomPacketPayload in net.neoforged.neoforge.common.extensions
Methods in net.neoforged.neoforge.common.extensions with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptiondefault voidIPlayerListExtension.broadcast(double x, double y, double z, double range, ResourceKey<Level> level, CustomPacketPayload payload) Sends a payload to all players within the specific level, within a given range around the target pointdefault voidIPlayerListExtension.broadcast(Player excludedPlayer, double x, double y, double z, double range, ResourceKey<Level> level, CustomPacketPayload payload) Sends a payload to all players within the specific level, within a given range around the target point, excluding the specified player.default voidIServerChunkCacheExtension.broadcast(Entity entity, CustomPacketPayload payload) Sends a payload to all players watching the given entity.default voidIPlayerListExtension.broadcastAll(CustomPacketPayload payload) Sends a payload to all players on the serverdefault voidIPlayerListExtension.broadcastAll(CustomPacketPayload payload, ResourceKey<Level> targetLevel) Sends a payload to all players within the specific level.default voidIServerChunkCacheExtension.broadcastAndSend(Entity entity, CustomPacketPayload payload) Sends a payload to all players watching the given entity.default booleanICommonPacketListener.hasChannel(CustomPacketPayload payload) default voidIClientCommonPacketListenerExtension.send(CustomPacketPayload payload) Sends a payload to the target of this listener.voidICommonPacketListener.send(CustomPacketPayload payload) Sends a payload to the target of this listener.default voidIServerCommonPacketListenerExtension.send(CustomPacketPayload payload) Sends a payload to the target of this listener.default voidIServerCommonPacketListenerExtension.send(CustomPacketPayload payload, @Nullable PacketSendListener listener) Sends a payload to the client of this listener.default voidIServerGamePacketListenerExtension.sendBundled(CustomPacketPayload... payloads) Sends all given payloads as a bundle to the client.Method parameters in net.neoforged.neoforge.common.extensions with type arguments of type CustomPacketPayloadModifier and TypeMethodDescriptiondefault voidIServerGamePacketListenerExtension.sendBundled(Iterable<CustomPacketPayload> payloads) Sends all given payloads as a bundle to the client.default voidIEntityExtension.sendPairingData(ServerPlayer serverPlayer, Consumer<CustomPacketPayload> bundleBuilder) Sends the pairing data to the client. -
Uses of CustomPacketPayload in net.neoforged.neoforge.debug.entity
Classes in net.neoforged.neoforge.debug.entity that implement CustomPacketPayloadMethod parameters in net.neoforged.neoforge.debug.entity with type arguments of type CustomPacketPayloadModifier and TypeMethodDescriptionvoidEntityTests.AdaptedSpawnEntity.sendPairingData(ServerPlayer serverPlayer, Consumer<CustomPacketPayload> bundleBuilder) -
Uses of CustomPacketPayload in net.neoforged.neoforge.network
Methods in net.neoforged.neoforge.network with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionprivate static Packet<?> PacketDistributor.makeClientboundPacket(CustomPacketPayload payload, CustomPacketPayload... payloads) static voidPacketDistributor.sendToAllPlayers(CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players on the serverstatic voidPacketDistributor.sendToPlayer(ServerPlayer player, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to the given playerstatic voidPacketDistributor.sendToPlayersInDimension(ServerLevel level, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players in the given dimensionstatic voidPacketDistributor.sendToPlayersNear(ServerLevel level, @Nullable ServerPlayer excluded, double x, double y, double z, double radius, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players in the area covered by the given radius around the given coordinates in the given dimension, except the given excluded player if presentstatic voidPacketDistributor.sendToPlayersTrackingChunk(ServerLevel level, ChunkPos chunkPos, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players tracking the chunk at the given position in the given levelstatic voidPacketDistributor.sendToPlayersTrackingEntity(Entity entity, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players tracking the given entitystatic voidPacketDistributor.sendToPlayersTrackingEntityAndSelf(Entity entity, CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to all players tracking the given entity and the entity itself if it is a playerstatic voidPacketDistributor.sendToServer(CustomPacketPayload payload, CustomPacketPayload... payloads) Send the given payload(s) to the server -
Uses of CustomPacketPayload in net.neoforged.neoforge.network.bundle
Methods in net.neoforged.neoforge.network.bundle with parameters of type CustomPacketPayload -
Uses of CustomPacketPayload in net.neoforged.neoforge.network.configuration
Method parameters in net.neoforged.neoforge.network.configuration with type arguments of type CustomPacketPayloadModifier and TypeMethodDescriptionvoidICustomConfigurationTask.run(Consumer<CustomPacketPayload> sender) Invoked when it is time for this configuration to run.voidRegistryDataMapNegotiation.run(Consumer<CustomPacketPayload> sender) voidSyncConfig.run(Consumer<CustomPacketPayload> sender) voidSyncRegistries.run(Consumer<CustomPacketPayload> sender) -
Uses of CustomPacketPayload in net.neoforged.neoforge.network.handling
Classes in net.neoforged.neoforge.network.handling with type parameters of type CustomPacketPayloadModifier and TypeClassDescriptionfinal recordDirectionalPayloadHandler<T extends CustomPacketPayload>Helper class that merges two unidirectional handlers into a single bidirectional handler.interfaceIPayloadHandler<T extends CustomPacketPayload>Callback for handling custom packets.final recordMainThreadPayloadHandler<T extends CustomPacketPayload>Helper class that always executes the wrapped handler on the main thread.Methods in net.neoforged.neoforge.network.handling with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionvoidClientPayloadContext.handle(CustomPacketPayload payload) voidIPayloadContext.handle(CustomPacketPayload payload) Handles a payload using the current context.voidServerPayloadContext.handle(CustomPacketPayload payload) default voidIPayloadContext.reply(CustomPacketPayload payload) Sends the given payload back to the sender. -
Uses of CustomPacketPayload in net.neoforged.neoforge.network.payload
Classes in net.neoforged.neoforge.network.payload that implement CustomPacketPayloadModifier and TypeClassDescriptionfinal recordPayload that can be sent from the server to the client to add an entity to the world, with custom data.final recordA custom payload that updates the full dataslot value instead of just the short valuefinal recordA custom payload that allows for opening screens with additional data.final recordfinal recordA payload that contains a config file.final recordPacket payload for sending a frozen registry to the clientfinal classThis payload is sent to the client when the server has finished sending all the frozen registries.final recordPacket payload sent to the client to start the frozen registry sync.final recordfinal recordfinal recordfinal recordfinal recordA payload that contains the modded network configuration and play components.final recordPayload for the modded network query request.final recordPayload sent to the client when the server has failed to set up the modded network.final recordfinal recordA payload that is used to split a packet into multiple payloads. -
Uses of CustomPacketPayload in net.neoforged.neoforge.network.registration
Classes in net.neoforged.neoforge.network.registration with type parameters of type CustomPacketPayloadModifier and TypeClassDescriptionfinal recordRegistration for a custom packet payload.final recordModdedPlayPayloadRegistration<T extends CustomPacketPayload>Registration for a custom packet payload.final recordPayloadRegistration<T extends CustomPacketPayload>Holds the information needed to describe a registered payload.Fields in net.neoforged.neoforge.network.registration with type parameters of type CustomPacketPayloadModifier and TypeFieldDescriptionprivate static final Map<ResourceLocation, StreamCodec<FriendlyByteBuf, ? extends CustomPacketPayload>> NetworkRegistry.BUILTIN_PAYLOADSMap of NeoForge payloads that may be sent before channel negotiation.Methods in net.neoforged.neoforge.network.registration with type parameters of type CustomPacketPayloadModifier and TypeMethodDescription<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.commonBidirectional(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a bidirectional payload for all phases.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.commonToClient(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a client-bound payload for all phases.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.commonToServer(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a server-bound payload for all phases.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.configurationBidirectional(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a bidirectional payload for the configuration phase.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.configurationToClient(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a client-bound payload for the configuration phase.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.configurationToServer(CustomPacketPayload.Type<T> type, StreamCodec<? super FriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a server-bound payload for the configuration phase.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.playBidirectional(CustomPacketPayload.Type<T> type, StreamCodec<? super RegistryFriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a bidirectional payload for the play phase.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.playToClient(CustomPacketPayload.Type<T> type, StreamCodec<? super RegistryFriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a client-bound payload for the play phase.<T extends CustomPacketPayload>
PayloadRegistrarPayloadRegistrar.playToServer(CustomPacketPayload.Type<T> type, StreamCodec<? super RegistryFriendlyByteBuf, T> reader, IPayloadHandler<T> handler) Registers a server-bound payload for the play phase.static <T extends CustomPacketPayload,B extends FriendlyByteBuf>
voidNetworkRegistry.register(CustomPacketPayload.Type<T> type, StreamCodec<? super B, T> codec, IPayloadHandler<T> handler, List<ConnectionProtocol> protocols, Optional<PacketFlow> flow, String version, boolean optional) Registers a new payload.private <T extends CustomPacketPayload,B extends FriendlyByteBuf>
voidPayloadRegistrar.register(CustomPacketPayload.Type<T> type, StreamCodec<? super B, T> codec, IPayloadHandler<T> handler, List<ConnectionProtocol> protocols, Optional<PacketFlow> flow, String version, boolean optional) Methods in net.neoforged.neoforge.network.registration that return types with arguments of type CustomPacketPayloadModifier and TypeMethodDescriptionstatic @Nullable StreamCodec<? super FriendlyByteBuf, ? extends CustomPacketPayload> NetworkRegistry.getCodec(ResourceLocation id, ConnectionProtocol protocol, PacketFlow flow) Attempts to retrieve theStreamCodecfor a non-vanilla payload.Methods in net.neoforged.neoforge.network.registration with parameters of type CustomPacketPayloadModifier and TypeMethodDescriptionstatic booleanNetworkRegistry.isModdedPayload(CustomPacketPayload payload) Checks if a payload is a modded payload. -
Uses of CustomPacketPayload in net.neoforged.neoforge.oldtest.misc
Classes in net.neoforged.neoforge.oldtest.misc that implement CustomPacketPayload -
Uses of CustomPacketPayload in net.neoforged.testframework.gametest
Methods in net.neoforged.testframework.gametest with type parameters of type CustomPacketPayloadModifier and TypeMethodDescription<T extends CustomPacketPayload>
Stream<T> GameTestPlayer.getOutboundPayloads(Class<T> type) -
Uses of CustomPacketPayload in net.neoforged.testframework.impl.packet
Classes in net.neoforged.testframework.impl.packet that implement CustomPacketPayloadModifier and TypeClassDescriptionfinal recordfinal recordMethods in net.neoforged.testframework.impl.packet that return types with arguments of type CustomPacketPayloadModifier and TypeMethodDescriptionCustomPacketPayload.Type<? extends CustomPacketPayload> ChangeEnabledPayload.type()CustomPacketPayload.Type<? extends CustomPacketPayload> ChangeStatusPayload.type()