Skip to content

Commit

Permalink
Update NBTTagCompoundPacketHandler.java
Browse files Browse the repository at this point in the history
  • Loading branch information
Fexcraft committed Dec 24, 2020
1 parent 9b61ce1 commit d323845
Showing 1 changed file with 14 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,13 @@ public void run(){
}
IPacketListener<PacketNBTTagCompound> listener = sls.get(packet.nbt.getString("target_listener"));
if(listener != null){
listener.process(packet, new Object[]{ctx.getServerHandler().player});
try{
listener.process(packet, new Object[]{ ctx.getServerHandler().player });
}
catch(Throwable thr){
Print.log("ERROR on processing NBT Packet: " + packet.nbt.toString());
thr.printStackTrace();
}
}
}
});
Expand All @@ -54,7 +60,13 @@ public void run(){
}
IPacketListener<PacketNBTTagCompound> listener = cls.get(packet.nbt.getString("target_listener"));
if(listener != null){
listener.process(packet, new Object[]{Minecraft.getMinecraft().player});
try{
listener.process(packet, new Object[]{ Minecraft.getMinecraft().player });
}
catch(Throwable thr){
Print.log("ERROR on processing NBT Packet: " + packet.nbt.toString());
thr.printStackTrace();
}
}
}
});
Expand Down

0 comments on commit d323845

Please sign in to comment.