give some info if a packat could not be translated

This commit is contained in:
WesleyVanNeck 2019-10-02 08:59:22 +02:00 committed by GitHub
parent 91a80f7dee
commit d85e565048
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,9 +53,10 @@ public class Registry<T> {
if (MAP.containsKey(clazz)) {
((PacketTranslator<P>) MAP.get(clazz)).translate(packet, session);
}
} catch (NullPointerException ex) {
GeyserLogger.DEFAULT.debug("Could not translate packet " + packet.getClass().getSimpleName());
} catch (Throwable ex) {
GeyserLogger.DEFAULT.debug("Could not translate packet " + packet.getClass().getSimpleName(), ex);
ex.printStackTrace();
}
return false;
}
}