Skip to content

Losin6450/PacketAddonDrupi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

PacketAddonDrupi

Requires: ProtocolLib

Example:

const PacketSystem = Java.type('me.losin6450.packetaddondrupi.PacketSystem');
const ListenerPriority = Java.type('com.comphenix.protocol.events.ListenerPriority');
const PacketType = Java.type('com.comphenix.protocol.PacketType');
const ProtocolLibrary = Java.type('com.comphenix.protocol.ProtocolLibrary');

ProtocolLibrary.getProtocolManager().removePacketListeners(plugin);

PacketSystem.addPacketListener(plugin, ListenerPriority.NORMAL, PacketType.Play.Client.CHAT, event => {}, event => {
    server.broadcastMessage(`${event.getPlayer().getName()} wrote ${event.getPacket().getStrings().read(0)}`);
});

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages