Description
Gallery
Changelog
Versions
VPacketEvents
Manage and register packets through Velocity's native events
class PacketListener {
@Subscribe
public void onPacketReceive(PacketReceiveEvent event) {
final MinecraftPacket packet = event.getPacket();
if (packet instanceof KeyedPlayerCommand commandPacket) {
event.setResult(GenericResult.denied());
}
}
@Subscribe
public void onPacketSend(PacketSendEvent event) {
// some stuff
}
public void registerPacket() {
// UpdateTeamsPacket registration
PacketRegistration.of(UpdateTeamsPacket.class)
.direction(Direction.CLIENTBOUND)
.packetSupplier(UpdateTeamsPacket::new)
.stateRegistry(StateRegistry.PLAY)
.mapping(0x47, MINECRAFT_1_13, false)
.mapping(0x4B, MINECRAFT_1_14, false)
.mapping(0x4C, MINECRAFT_1_15, false)
.mapping(0x55, MINECRAFT_1_17, false)
.mapping(0x58, MINECRAFT_1_19_1, false)
.mapping(0x56, MINECRAFT_1_19_3, false)
.mapping(0x5A, MINECRAFT_1_19_4, false)
.register();
}
}
Installation
- Download VPacketEvents from Modrinth
- Drag and drop on your plugins folder
- Start the server
Dev Setup
Gradle
repositories {
mavenCentral()
}
dependencies {
compileOnly("io.github.4drian3d:vpacketevents-api:1.1.0")
}
Javadocs
All Versions
+ Add Version
[1.2.0] VPacketEvents 1.2.0
by 4drian3d on Oct 12, 2026
Download
## What's Changed
- Updated to Java 25
- Updated to Velocity 4
- Deprecated and replaced API method
PacketRegistration#ofwithPacketRegistration#ofPacket - Replaced Jetbrains annotations with JSpecify
- Full Changelog**: https://github.com/4drian3d/VPacketEvents/compare/1.1.0...1.2.0
[1.1.0] VPacketEvents 1.1.0
by 4drian3d on Oct 12, 2026
Download
New API added for easy packet registration in Velocity
``
## What's Changed
``
java
// Example of UpdateTeam registration
PacketRegistration.of(UpdateTeamsPacket.class)
.direction(Direction.CLIENTBOUND)
.packetSupplier(UpdateTeamsPacket::new)
.stateRegistry(StateRegistry.PLAY)
.mapping(0x47, MINECRAFT_1_13, false)
.mapping(0x4B, MINECRAFT_1_14, false)
.mapping(0x4C, MINECRAFT_1_15, false)
.mapping(0x55, MINECRAFT_1_17, false)
.mapping(0x58, MINECRAFT_1_19_1, false)
.mapping(0x56, MINECRAFT_1_19_3, false)
.mapping(0x5A, MINECRAFT_1_19_4, false)
.register();
``## What's Changed
- chore(deps): update dependency gradle to v8.1 in https://github.com/4drian3d/VPacketEvents/pull/9
- Added Packet Registration capability in https://github.com/4drian3d/VPacketEvents/pull/10
- Full Changelog**: https://github.com/4drian3d/VPacketEvents/compare/1.0.2...1.1.0
[1.0.2] VPacketEvents 1.0.2
by 4drian3d on Oct 12, 2026
Download
This update is mostly about fixing an incompatibility with LimboAPI, which for some reason completely replaces a fundamental function of Velocity, with the possibility of breaking certain plugins in some setups
## What's Changed
## What's Changed
- chore(deps): update dependency com.github.johnrengelman.shadow to v8 in https://github.com/4drian3d/VPacketEvents/pull/2
- chore(deps): update dependency gradle to v8.0.2 in https://github.com/4drian3d/VPacketEvents/pull/4
- fix(deps): update dependency io.netty:netty-all to v4.1.90.final in https://github.com/4drian3d/VPacketEvents/pull/6
- chore(deps): update dependency com.github.johnrengelman.shadow to v8.1.1 in https://github.com/4drian3d/VPacketEvents/pull/7
- fix(deps): update dependency io.netty:netty-all to v4.1.91.final in https://github.com/4drian3d/VPacketEvents/pull/8
- [fix: Catch possible exception throwing on PacketEvents execution](https://github.com/4drian3d/VPacketEvents/commit/2cbb516c97edaf7397c00824f325441ab9eb73a8)
- [misc: Update to Java 17](https://github.com/4drian3d/VPacketEvents/commit/fc6311602bf2e5bb9b0198644aa7e806a20428fe)
- [fix: Added support to LimboAPI's unsupported behavior](https://github.com/4drian3d/VPacketEvents/commit/7f77ab3529fc8703dbc4967f75d273df92b4bea2)
- Full Changelog**: https://github.com/4drian3d/VPacketEvents/compare/1.0.1...1.0.2
[1.0.1] VPacketEvents 1.0.1
by 4drian3d on Oct 12, 2026
Download
- Fixed version string in initialization
- Some javadoc fixes
- Full Changelog**: https://github.com/4drian3d/VPacketEvents/compare/1.0.0...1.0.1
