From b5f3edc3a17bc6f9891c4a523ddeae839790263d Mon Sep 17 00:00:00 2001 From: libraryaddict Date: Sun, 29 Mar 2020 18:28:45 +1300 Subject: [PATCH] Just because I'm left handed doesn't mean the others are not right --- .../disguisetypes/watchers/PlayerWatcher.java | 57 ++++++++++--------- 1 file changed, 29 insertions(+), 28 deletions(-) diff --git a/src/main/java/me/libraryaddict/disguise/disguisetypes/watchers/PlayerWatcher.java b/src/main/java/me/libraryaddict/disguise/disguisetypes/watchers/PlayerWatcher.java index ef5d3374..d8b969f4 100644 --- a/src/main/java/me/libraryaddict/disguise/disguisetypes/watchers/PlayerWatcher.java +++ b/src/main/java/me/libraryaddict/disguise/disguisetypes/watchers/PlayerWatcher.java @@ -15,6 +15,7 @@ public class PlayerWatcher extends LivingWatcher { super(disguise); setData(MetaIndex.PLAYER_SKIN, MetaIndex.PLAYER_SKIN.getDefault()); + setData(MetaIndex.PLAYER_HAND, (byte) 1); // I may be left handed, but the others are right } public boolean isDisplayedInTab() { @@ -35,15 +36,15 @@ public class PlayerWatcher extends LivingWatcher { return watcher; } + public MainHand getMainHand() { + return MainHand.values()[getData(MetaIndex.PLAYER_HAND)]; + } + public void setMainHand(MainHand mainHand) { setData(MetaIndex.PLAYER_HAND, (byte) mainHand.ordinal()); sendData(MetaIndex.PLAYER_HAND); } - public MainHand getMainHand() { - return MainHand.values()[getData(MetaIndex.PLAYER_HAND)]; - } - // Bit 0 (0x01): Cape enabled // Bit 1 (0x02): Jacket enabled // Bit 2 (0x04): Left Sleeve enabled @@ -60,66 +61,66 @@ public class PlayerWatcher extends LivingWatcher { return isSkinFlag(1); } - public boolean isJacketEnabled() { - return isSkinFlag(2); - } - - public boolean isLeftSleeveEnabled() { - return isSkinFlag(3); - } - - public boolean isRightSleeveEnabled() { - return isSkinFlag(4); - } - - public boolean isLeftPantsEnabled() { - return isSkinFlag(5); - } - - public boolean isRightPantsEnabled() { - return isSkinFlag(6); - } - - public boolean isHatEnabled() { - return isSkinFlag(7); - } - public void setCapeEnabled(boolean enabled) { setSkinFlags(1, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isJacketEnabled() { + return isSkinFlag(2); + } + public void setJacketEnabled(boolean enabled) { setSkinFlags(2, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isLeftSleeveEnabled() { + return isSkinFlag(3); + } + public void setLeftSleeveEnabled(boolean enabled) { setSkinFlags(3, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isRightSleeveEnabled() { + return isSkinFlag(4); + } + public void setRightSleeveEnabled(boolean enabled) { setSkinFlags(4, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isLeftPantsEnabled() { + return isSkinFlag(5); + } + public void setLeftPantsEnabled(boolean enabled) { setSkinFlags(5, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isRightPantsEnabled() { + return isSkinFlag(6); + } + public void setRightPantsEnabled(boolean enabled) { setSkinFlags(6, enabled); sendData(MetaIndex.PLAYER_SKIN); } + public boolean isHatEnabled() { + return isSkinFlag(7); + } + public void setHatEnabled(boolean enabled) { setSkinFlags(7, enabled);