Class NetworkEvent
java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.fmllegacy.network.NetworkEvent
- Direct Known Subclasses:
NetworkEvent.ChannelRegistrationChangeEvent
,NetworkEvent.ClientCustomPayloadEvent
,NetworkEvent.LoginPayloadEvent
,NetworkEvent.ServerCustomPayloadEvent
public class NetworkEvent
extends net.minecraftforge.eventbus.api.Event
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Fired when the channel registration (see minecraft custom channel documentation) changes.static class
static class
static class
Context forNetworkEvent
static class
static class
static class
static class
static class
Nested classes/interfaces inherited from class net.minecraftforge.eventbus.api.Event
net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
-
Field Summary
Modifier and TypeFieldDescriptionprivate int
private FriendlyByteBuf
private Supplier<NetworkEvent.Context>
-
Constructor Summary
ModifierConstructorDescriptionNetworkEvent(Supplier<NetworkEvent.Context> source)
private
NetworkEvent(FriendlyByteBuf payload, Supplier<NetworkEvent.Context> source, int loginIndex)
private
NetworkEvent(ICustomPacket<?> payload, Supplier<NetworkEvent.Context> source)
-
Method Summary
Modifier and TypeMethodDescriptionint
Methods inherited from class net.minecraftforge.eventbus.api.Event
getListenerList, getParentListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult, setup
-
Field Details
-
payload
-
source
-
loginIndex
private final int loginIndex
-
-
Constructor Details
-
NetworkEvent
-
NetworkEvent
private NetworkEvent(FriendlyByteBuf payload, Supplier<NetworkEvent.Context> source, int loginIndex) -
NetworkEvent
-
-
Method Details
-
getPayload
-
getSource
-
getLoginIndex
public int getLoginIndex()
-