Packets implement Pcaket right
This commit is contained in:
parent
b3caf7c2d4
commit
ddd674e371
@ -4,6 +4,9 @@ import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import net.minecraft.server.v1_8_R3.Packet;
|
||||
|
||||
import org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.EventHandler;
|
||||
@ -64,7 +67,7 @@ public class PacketHandler extends MiniPlugin
|
||||
return _playerVerifierMap.get(player);
|
||||
}
|
||||
|
||||
public void addPacketHandler(IPacketHandler packetHandler, Class... packetsToListen)
|
||||
public void addPacketHandler(IPacketHandler packetHandler, Class<? extends Packet>... packetsToListen)
|
||||
{
|
||||
if (packetsToListen.length == 0)
|
||||
{
|
||||
@ -77,7 +80,7 @@ public class PacketHandler extends MiniPlugin
|
||||
/**
|
||||
* This should only be used for incoming packets
|
||||
*/
|
||||
public void addPacketHandler(IPacketHandler packetHandler, boolean forceMainThread, Class... packetsToListen)
|
||||
public void addPacketHandler(IPacketHandler packetHandler, boolean forceMainThread, Class<? extends Packet>... packetsToListen)
|
||||
{
|
||||
if (packetsToListen.length == 0)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user