diff --git a/bukkit/src/main/java/com/clubobsidian/dynamicgui/bukkit/entity/BukkitPlayerWrapper.java b/bukkit/src/main/java/com/clubobsidian/dynamicgui/bukkit/entity/BukkitPlayerWrapper.java index fd5534f3e..96d92b5b3 100644 --- a/bukkit/src/main/java/com/clubobsidian/dynamicgui/bukkit/entity/BukkitPlayerWrapper.java +++ b/bukkit/src/main/java/com/clubobsidian/dynamicgui/bukkit/entity/BukkitPlayerWrapper.java @@ -213,9 +213,9 @@ public String getSkinTexture() { if (property == null) { return null; } - return (String) property.getClass().getDeclaredMethod("getValue").invoke(property); - } catch (NoSuchMethodException | IllegalAccessException | InvocationTargetException | - ClassNotFoundException e) { + return (String) ReflectionUtil.getDeclaredField(property.getClass(), "value").get(property); + } catch (NoSuchMethodException | IllegalAccessException | InvocationTargetException + | ClassNotFoundException e) { e.printStackTrace(); return null; }