ProtocolLib bukkit plugins 1.7.9
Certain tasks are impossible to perform with the standard Bukkit API, and may require working with and even modify Minecraft directly. A common technique is to modify incoming and outgoing packets, or inject custom packets into the stream. This is quite cumbersome to do, however, and most implementations will break as soon as a new version of Minecraft has been released, mostly due to obfuscation.
Critically, different plugins that use this approach may hook into the same classes, with unpredictable outcomes. More than often this causes plugins to crash, but it may also lead to more subtle bugs.
For server operators
Just download ProtocolLib from the link above. It doesn’t do anything on its own, it simply allows other plugins to function.
Source code for a bunch of example programs that use ProtocolLib can be found at this thread on the main support forum.
You may also be interested in PacketWrapper, a library that makes it possible to modify a packet without having to decompile the Minecraft source code.
Finally, for the more advanced users who want to use ProtocolLib if present, but still fall back on their own packet listening system, I recommend taking a look at this thread. I explain where and how to inject code into CraftBukkit in order to intercept sent and received packets yourself.
If you’re using Maven, you’ll be able to automatically download the JAR, JavaDoc and associated sources from the following repository:
<repositories> <repository> <id>comphenix-rep</id> <name>Comphenix Repository</name> <url>http://repo.comphenix.net/content/groups/public</url> </repository> <!-- And so on --> </repositories>
This repository contains ProtocolLib, TagHelper and BlockPatcher. You can add any of them as a dependency like so:
<dependencies> <dependency> <groupId>com.comphenix.protocol</groupId> <artifactId>ProtocolLib</artifactId> <version>2.7.0</version> </dependency> </dependencies>
Main administrative command. Supports the following sub-commands:
- config: Reload the configuration file.
- check: Check for new versions on BukkitDev.
- update: Check for new versions and automatically download the JAR. The server must be restarted for this to take effect.
- timings: Toggle measuring the amount of CPU time spent by each plugin. See here for more
There’s a couple of new things worth upgrading in this update – first, there’s a number of bug fixes mainly addressed at Spigot, such as a server-crash during reloading (ticket 127), a PlayerLoggedOutException (ticket 131) and support for snapshot protocol versions. But I’ve also added some very needed volatile keywords, where multiple threads were reading and updating the same variable. That should make the infamous “Unknown origin” error message less likely.
In addition, I’ve also added a way to measure the time taken by each packet listener:
- Timings Command
- Add the ability to track the amount of time spent by each plugin.
- Intercept packets sent during the handling of PlayerLoginEvent.
- Relax expected Minecraft version format. Partially fixes ticket 124
- Cleanup proxy packet injector in Spigot too. FIXES 127
- Experimental: Correct a possible race condition with Spigot.
- These fields will be updated and read from different threads. Use volatile.
- Attempt to handle snapshot versions by assuming Minecraft version.
- Don’t choke on exceptions during error filtering. Pointless.
- More descriptive error message when an entities tracker is not found.
Download ProtocolLib bukkit plugins