Class PacketEvent
java.lang.Object
org.polyfrost.oneconfig.api.event.v1.events.Event.Cancellable
org.polyfrost.oneconfig.api.event.v1.events.PacketEvent
- All Implemented Interfaces:
Event
- Direct Known Subclasses:
PacketEvent.Receive,PacketEvent.Send
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classstatic final classNested classes/interfaces inherited from interface org.polyfrost.oneconfig.api.event.v1.events.Event
Event.Cancellable -
Field Summary
Fields inherited from class org.polyfrost.oneconfig.api.event.v1.events.Event.Cancellable
cancelled -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> TDue to differences across Minecraft versions, this is a Duck method, meaning that it will return the expected type for that minecraft version.
-
Constructor Details
-
PacketEvent
-
-
Method Details
-
getPacket
public <T> T getPacket()Due to differences across Minecraft versions, this is a Duck method, meaning that it will return the expected type for that minecraft version.- For legacy forge, this will be a IPacket.
- For modern forge, this will be a Packet.
- For fabric, this will be a Packet.
-
component1
-