Package net.minecraft.network
Class ConnectionProtocol.PacketSet<T extends PacketListener>
java.lang.Object
net.minecraft.network.ConnectionProtocol.PacketSet<T>
- Enclosing class:
- ConnectionProtocol
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription<P extends Packet<T>>
ConnectionProtocol.PacketSet<T>addPacket(Class<P> p_178331_, Function<FriendlyByteBuf,P> p_178332_)
Packet<?>
createPacket(int p_178328_, FriendlyByteBuf p_178329_)
-
Field Details
-
classToId
private final it.unimi.dsi.fastutil.objects.Object2IntMap<Class<? extends Packet<T extends PacketListener>>> classToId -
idToDeserializer
private final List<Function<FriendlyByteBuf,? extends Packet<T extends PacketListener>>> idToDeserializer
-
-
Constructor Details
-
PacketSet
PacketSet()
-
-
Method Details
-
addPacket
public <P extends Packet<T>> ConnectionProtocol.PacketSet<T> addPacket(Class<P> p_178331_, Function<FriendlyByteBuf,P> p_178332_) -
getId
-
createPacket
-
getAllPackets
-