Package-level declarations

Types

Link copied to clipboard
interface LegacyPacket

A packet that is directly sent to the server over ViaVersion.

Link copied to clipboard
Link copied to clipboard

https://github.com/ViaVersion/ViaFabricPlus/blob/ecd5d188187f2ebaaad8ded0ffe53538911f7898/src/main/java/de/florianmichael/viafabricplus/injection/mixin/fixes/minecraft/MixinMinecraftClient.java#L124-L130

Link copied to clipboard
data class PickFromInventoryPacket(val slot: Int) : LegacyPacket

https://github.com/ViaVersion/ViaFabricPlus/blob/1957a175e4a4bff50860c0b3359d5219624fe434/src/main/java/com/viaversion/viafabricplus/features/world/item_picking/ItemPick1_21_3.java#L123

Link copied to clipboard

https://github.com/ViaVersion/ViaFabricPlus/blob/56c4959000e68d77fd415b89af7a95478d825079/src/main/java/com/viaversion/viafabricplus/injection/mixin/features/movement/sprinting_and_sneaking/MixinClientPlayerEntity.java#L251-L264

Properties

Link copied to clipboard

In version <= 1.21.11 ServerboundAttackPacket&ServerboundSpectateEntityPacket belong to ServerboundInteractPacket

Link copied to clipboard
val packetRegistry: EnumMap<PacketFlow, MutableSet<Identifier>>

A registry for packet types, allowing registration of packet identifiers for both clientbound and serverbound packets. This is used to keep track of which packets are registered for each side of the network.

Link copied to clipboard
val ServerboundMovePlayerPacket.position: Vec3

Functions

Link copied to clipboard
fun LocalPlayer.clickBlockWithSlot(rayTraceResult: BlockHitResult, slot: Int, swingMode: SwingMode, switchMode: SwitchMode = SwitchMode.SILENT, sequenced: Boolean = true)
Link copied to clipboard
fun handlePacket(packet: Packet<*>): Result<Unit>
Link copied to clipboard
fun Packet<*>?.isC2SContainerPacket(): Boolean
Link copied to clipboard
fun Packet<*>?.isLocalPlayerDamage(): Boolean
Link copied to clipboard
fun Packet<*>?.isLocalPlayerVelocity(considerExplosion: Boolean = true): Boolean
Link copied to clipboard
fun ClientboundSetEntityMotionPacket.isMovementYFallDamage(): Boolean
Link copied to clipboard
fun MultiPlayerGameMode.releaseUsingItemInTickLoop()
Link copied to clipboard
fun ClientCommonPacketListenerImpl.send1_11_1OpenInventory()

Sends an open inventory packet with the help of ViaFabricPlus. This is only for older versions. (<= 1.11.2)

Link copied to clipboard
fun ClientCommonPacketListenerImpl.send1_21_5StartSneaking()
Link copied to clipboard
fun ClientCommonPacketListenerImpl.send1_21_5StopSneaking()
Link copied to clipboard
fun ClientPacketListener.sendChatOrCommand(message: String)
Link copied to clipboard
fun ClientCommonPacketListenerImpl.sendCloseInventory()
Link copied to clipboard
fun ClientCommonPacketListenerImpl.sendHeldItemChange(slot: Int)
Link copied to clipboard
inline fun ClientCommonPacketListenerImpl.sendPacket(packet: LegacyPacket, onSuccess: () -> Unit = {}, onFailure: () -> Unit = {})

Sends the packet.

Link copied to clipboard
fun sendPacketSilently(packet: Packet<*>)
Link copied to clipboard
fun ClientCommonPacketListenerImpl.sendStartSprinting()
Link copied to clipboard
fun ClientCommonPacketListenerImpl.sendStopSprinting()
Link copied to clipboard
fun ClientCommonPacketListenerImpl.sendSwapItemWithOffhand()
Link copied to clipboard
fun MultiPlayerGameMode.useItem(player: Player, hand: InteractionHand, yRot: Float, xRot: Float): InteractionResult

MultiPlayerGameMode.useItem but with custom rotations.