diff --git a/src/main/java/emu/grasscutter/net/packet/PacketOpcodesUtil.java b/src/main/java/emu/grasscutter/net/packet/PacketOpcodesUtil.java index 6395a7d4d..ff7be1e45 100644 --- a/src/main/java/emu/grasscutter/net/packet/PacketOpcodesUtil.java +++ b/src/main/java/emu/grasscutter/net/packet/PacketOpcodesUtil.java @@ -17,10 +17,12 @@ public class PacketOpcodesUtil { Field[] fields = PacketOpcodes.class.getFields(); for (Field f : fields) { - try { - opcodeMap.put(f.getInt(null), f.getName()); - } catch (Exception e) { - e.printStackTrace(); + if(f.getType().equals(int.class)) { + try { + opcodeMap.put(f.getInt(null), f.getName()); + } catch (Exception e) { + e.printStackTrace(); + } } } }