From 384a20ab6e68f44ce43fccba9b3b5790c519dc34 Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 24 Jul 2013 15:57:05 +1200 Subject: [PATCH] Fixed a error when custom name longer then 64, fixed derp with a method return --- .../disguise/DisguiseTypes/Watchers/LivingWatcher.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/me/libraryaddict/disguise/DisguiseTypes/Watchers/LivingWatcher.java b/src/me/libraryaddict/disguise/DisguiseTypes/Watchers/LivingWatcher.java index f57d1245..d3691dfd 100644 --- a/src/me/libraryaddict/disguise/DisguiseTypes/Watchers/LivingWatcher.java +++ b/src/me/libraryaddict/disguise/DisguiseTypes/Watchers/LivingWatcher.java @@ -84,13 +84,15 @@ public class LivingWatcher extends FlagWatcher { public void setCustomName(String name) { if (!getCustomName().equals(name)) { + if (name.length() > 64) + name = name.substring(0, 64); setValue(10, name); sendData(10); } } public void setCustomNameVisible(boolean display) { - if (this.isCustomNameVisible()) { + if (isCustomNameVisible() != display) { setValue(11, (byte) (display ? 1 : 0)); sendData(11); }