Class PacketPlayOutAdvancementsWrapper
java.lang.Object
com.fren_gor.ultimateAdvancementAPI.nms.wrappers.packets.PacketPlayOutAdvancementsWrapper
- All Implemented Interfaces:
ISendable
Wrapper class for NMS
PacketPlayOutAdvancements
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncraftRemovePacket
(@NotNull Set<MinecraftKeyWrapper> toRemove) Creates a newPacketPlayOutAdvancementsWrapper
which removes some advancements from the advancement GUI.Creates a newPacketPlayOutAdvancementsWrapper
which removes every previously sent advancement from the advancement GUI.craftSendPacket
(@NotNull Map<AdvancementWrapper, Integer> toSend) Creates a newPacketPlayOutAdvancementsWrapper
which adds some advancements to the advancement GUI.
-
Constructor Details
-
PacketPlayOutAdvancementsWrapper
public PacketPlayOutAdvancementsWrapper()
-
-
Method Details
-
craftResetPacket
@NotNull public static @NotNull PacketPlayOutAdvancementsWrapper craftResetPacket() throws ReflectiveOperationExceptionCreates a newPacketPlayOutAdvancementsWrapper
which removes every previously sent advancement from the advancement GUI.- Returns:
- A new
PacketPlayOutAdvancementsWrapper
which removes every previously sent advancement from the advancement GUI. - Throws:
ReflectiveOperationException
- If reflections goes wrong.
-
craftSendPacket
@NotNull public static @NotNull PacketPlayOutAdvancementsWrapper craftSendPacket(@NotNull @NotNull Map<AdvancementWrapper, Integer> toSend) throws ReflectiveOperationExceptionCreates a newPacketPlayOutAdvancementsWrapper
which adds some advancements to the advancement GUI.- Parameters:
toSend
- TheMap
of the advancement to send paired with their respective progressions to display.- Returns:
- A new
PacketPlayOutAdvancementsWrapper
which adds some advancements to the advancement GUI. - Throws:
ReflectiveOperationException
- If reflections goes wrong.
-
craftRemovePacket
@NotNull public static @NotNull PacketPlayOutAdvancementsWrapper craftRemovePacket(@NotNull @NotNull Set<MinecraftKeyWrapper> toRemove) throws ReflectiveOperationException Creates a newPacketPlayOutAdvancementsWrapper
which removes some advancements from the advancement GUI.- Parameters:
toRemove
- TheSet
containing the namespaced keys of the advancements to remove.- Returns:
- A new
PacketPlayOutAdvancementsWrapper
which removes some advancements from the advancement GUI. - Throws:
ReflectiveOperationException
- If reflections goes wrong.
-