2013-09-25 16:49:24 +02:00
|
|
|
package me.libraryaddict.disguise.disguisetypes;
|
2013-05-17 23:05:19 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
import java.lang.reflect.InvocationTargetException;
|
|
|
|
import java.util.Arrays;
|
|
|
|
import java.util.UUID;
|
|
|
|
|
2016-05-09 17:28:38 +02:00
|
|
|
import org.apache.commons.lang.Validate;
|
2016-11-30 05:08:12 +01:00
|
|
|
import org.bukkit.Bukkit;
|
2016-05-09 17:28:38 +02:00
|
|
|
import org.bukkit.entity.Entity;
|
|
|
|
import org.bukkit.entity.Player;
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
import com.comphenix.protocol.PacketType;
|
|
|
|
import com.comphenix.protocol.ProtocolLibrary;
|
|
|
|
import com.comphenix.protocol.events.PacketContainer;
|
|
|
|
import com.comphenix.protocol.wrappers.EnumWrappers.NativeGameMode;
|
|
|
|
import com.comphenix.protocol.wrappers.EnumWrappers.PlayerInfoAction;
|
|
|
|
import com.comphenix.protocol.wrappers.PlayerInfoData;
|
|
|
|
import com.comphenix.protocol.wrappers.WrappedChatComponent;
|
2014-06-04 22:40:15 +02:00
|
|
|
import com.comphenix.protocol.wrappers.WrappedGameProfile;
|
2016-05-09 17:28:38 +02:00
|
|
|
|
2015-03-29 00:59:42 +01:00
|
|
|
import me.libraryaddict.disguise.LibsDisguises;
|
2014-09-05 12:31:16 +02:00
|
|
|
import me.libraryaddict.disguise.disguisetypes.watchers.PlayerWatcher;
|
2014-05-31 20:47:05 +02:00
|
|
|
import me.libraryaddict.disguise.utilities.DisguiseUtilities;
|
|
|
|
import me.libraryaddict.disguise.utilities.LibsProfileLookup;
|
|
|
|
import me.libraryaddict.disguise.utilities.ReflectionManager;
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public class PlayerDisguise extends TargetedDisguise {
|
2014-05-31 20:47:05 +02:00
|
|
|
private LibsProfileLookup currentLookup;
|
2014-06-04 22:40:15 +02:00
|
|
|
private WrappedGameProfile gameProfile;
|
2013-05-17 23:05:19 +02:00
|
|
|
private String playerName;
|
2014-05-31 20:47:05 +02:00
|
|
|
private String skinToUse;
|
2016-11-30 05:08:12 +01:00
|
|
|
private UUID uuid = UUID.randomUUID();
|
2013-05-17 23:05:19 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
private PlayerDisguise() {
|
2016-11-30 18:38:43 +01:00
|
|
|
super(DisguiseType.PLAYER);
|
2013-05-17 23:05:19 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(Player player) {
|
2016-05-12 13:30:22 +02:00
|
|
|
this(ReflectionManager.getGameProfile(player));
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(Player player, Player skinToUse) {
|
2016-06-05 15:31:34 +02:00
|
|
|
this(ReflectionManager.getGameProfile(player), ReflectionManager.getGameProfile(skinToUse));
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(String name) {
|
2016-11-30 18:38:43 +01:00
|
|
|
this();
|
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
setName(name);
|
|
|
|
setSkin(name);
|
|
|
|
|
2016-11-30 18:38:43 +01:00
|
|
|
createDisguise();
|
2016-06-14 11:08:53 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(String name, String skinToUse) {
|
2016-11-30 18:38:43 +01:00
|
|
|
this();
|
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
setName(name);
|
|
|
|
setSkin(skinToUse);
|
|
|
|
|
2016-11-30 18:38:43 +01:00
|
|
|
createDisguise();
|
2016-06-14 11:08:53 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(WrappedGameProfile gameProfile) {
|
2016-11-30 18:38:43 +01:00
|
|
|
this();
|
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
setName(gameProfile.getName());
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
this.gameProfile = ReflectionManager.getGameProfileWithThisSkin(uuid, gameProfile.getName(), gameProfile);
|
2016-06-14 11:08:53 +02:00
|
|
|
|
2016-11-30 18:38:43 +01:00
|
|
|
createDisguise();
|
2014-09-29 06:05:04 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise(WrappedGameProfile gameProfile, WrappedGameProfile skinToUse) {
|
2016-11-30 18:38:43 +01:00
|
|
|
this();
|
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
setName(gameProfile.getName());
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
this.gameProfile = ReflectionManager.getGameProfile(uuid, gameProfile.getName());
|
2016-06-05 15:31:34 +02:00
|
|
|
|
|
|
|
setSkin(skinToUse);
|
2016-06-14 11:08:53 +02:00
|
|
|
|
2016-11-30 18:38:43 +01:00
|
|
|
createDisguise();
|
2016-06-05 15:31:34 +02:00
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise addPlayer(Player player) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.addPlayer(player);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise addPlayer(String playername) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.addPlayer(playername);
|
|
|
|
}
|
|
|
|
|
2013-11-05 17:37:10 +01:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise clone() {
|
2016-06-14 11:08:53 +02:00
|
|
|
PlayerDisguise disguise = new PlayerDisguise();
|
|
|
|
|
|
|
|
disguise.playerName = getName();
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
if (disguise.currentLookup == null && disguise.gameProfile != null) {
|
2014-05-31 20:47:05 +02:00
|
|
|
disguise.skinToUse = getSkin();
|
2016-11-30 05:08:12 +01:00
|
|
|
disguise.gameProfile = ReflectionManager.getGameProfileWithThisSkin(disguise.uuid, getGameProfile().getName(),
|
|
|
|
getGameProfile());
|
2016-05-12 13:30:22 +02:00
|
|
|
}
|
2016-11-30 05:08:12 +01:00
|
|
|
else {
|
2014-05-31 20:47:05 +02:00
|
|
|
disguise.setSkin(getSkin());
|
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2014-05-14 00:34:41 +02:00
|
|
|
disguise.setReplaceSounds(isSoundsReplaced());
|
2013-11-22 20:52:15 +01:00
|
|
|
disguise.setViewSelfDisguise(isSelfDisguiseVisible());
|
2013-11-22 21:19:30 +01:00
|
|
|
disguise.setHearSelfDisguise(isSelfDisguiseSoundsReplaced());
|
2013-11-05 17:37:10 +01:00
|
|
|
disguise.setHideArmorFromSelf(isHidingArmorFromSelf());
|
|
|
|
disguise.setHideHeldItemFromSelf(isHidingHeldItemFromSelf());
|
|
|
|
disguise.setVelocitySent(isVelocitySent());
|
2014-01-04 10:15:18 +01:00
|
|
|
disguise.setModifyBoundingBox(isModifyBoundingBox());
|
2016-10-05 11:36:40 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
if (getWatcher() != null) {
|
2016-10-05 11:36:40 +02:00
|
|
|
disguise.setWatcher(getWatcher().clone(disguise));
|
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-11-30 18:38:43 +01:00
|
|
|
disguise.createDisguise();
|
2013-07-16 07:23:38 +02:00
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
return disguise;
|
2014-09-29 06:05:04 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public WrappedGameProfile getGameProfile() {
|
|
|
|
if (gameProfile == null) {
|
|
|
|
if (getSkin() != null) {
|
|
|
|
gameProfile = ReflectionManager.getGameProfile(uuid, getName());
|
2016-05-12 13:30:22 +02:00
|
|
|
}
|
2016-11-30 05:08:12 +01:00
|
|
|
else {
|
|
|
|
gameProfile = ReflectionManager.getGameProfileWithThisSkin(uuid, getName(),
|
2016-05-12 13:30:22 +02:00
|
|
|
DisguiseUtilities.getProfileFromMojang(this));
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2014-09-29 06:05:04 +02:00
|
|
|
return gameProfile;
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public String getName() {
|
2013-05-17 23:05:19 +02:00
|
|
|
return playerName;
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public String getSkin() {
|
2014-05-31 20:47:05 +02:00
|
|
|
return skinToUse;
|
|
|
|
}
|
|
|
|
|
2014-09-05 12:31:16 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerWatcher getWatcher() {
|
2014-09-05 12:31:16 +02:00
|
|
|
return (PlayerWatcher) super.getWatcher();
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public boolean isDisplayedInTab() {
|
|
|
|
return getWatcher().isDisplayedInTab();
|
|
|
|
}
|
|
|
|
|
2013-12-01 17:10:38 +01:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public boolean isPlayerDisguise() {
|
2013-12-01 17:10:38 +01:00
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise removePlayer(Player player) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.removePlayer(player);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise removePlayer(String playername) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.removePlayer(playername);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setDisguiseTarget(TargetType newTargetType) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.setDisguiseTarget(newTargetType);
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public void setDisplayedInTab(boolean showPlayerInTab) {
|
|
|
|
getWatcher().setDisplayedInTab(showPlayerInTab);
|
|
|
|
}
|
|
|
|
|
2014-07-11 06:36:47 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setEntity(Entity entity) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setEntity(entity);
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public void setGameProfile(WrappedGameProfile gameProfile) {
|
|
|
|
this.gameProfile = ReflectionManager.getGameProfileWithThisSkin(uuid, gameProfile.getName(), gameProfile);
|
2016-06-14 11:08:53 +02:00
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setHearSelfDisguise(boolean hearSelfDisguise) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setHearSelfDisguise(hearSelfDisguise);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setHideArmorFromSelf(boolean hideArmor) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setHideArmorFromSelf(hideArmor);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setHideHeldItemFromSelf(boolean hideHeldItem) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setHideHeldItemFromSelf(hideHeldItem);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setKeepDisguiseOnEntityDespawn(boolean keepDisguise) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setKeepDisguiseOnEntityDespawn(keepDisguise);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setKeepDisguiseOnPlayerDeath(boolean keepDisguise) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setKeepDisguiseOnPlayerDeath(keepDisguise);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setKeepDisguiseOnPlayerLogout(boolean keepDisguise) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setKeepDisguiseOnPlayerLogout(keepDisguise);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setModifyBoundingBox(boolean modifyBox) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setModifyBoundingBox(modifyBox);
|
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
private void setName(String name) {
|
|
|
|
if (name.length() > 16) {
|
2016-06-14 11:08:53 +02:00
|
|
|
name = name.substring(0, 16);
|
|
|
|
}
|
|
|
|
|
|
|
|
playerName = name;
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setReplaceSounds(boolean areSoundsReplaced) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setReplaceSounds(areSoundsReplaced);
|
2014-07-11 06:36:47 +02:00
|
|
|
}
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setSkin(String newSkin) {
|
2016-11-30 18:38:43 +01:00
|
|
|
if (newSkin != null && newSkin.length() > 50) {
|
|
|
|
try {
|
|
|
|
setSkin(ReflectionManager.parseGameProfile(newSkin));
|
|
|
|
}
|
|
|
|
catch (Exception ex) {
|
|
|
|
throw new IllegalArgumentException(
|
|
|
|
"The skin is too long to be a playername, but cannot be parsed to a GameProfile!");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
skinToUse = newSkin;
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
if (newSkin == null) {
|
2016-06-14 11:08:53 +02:00
|
|
|
currentLookup = null;
|
|
|
|
gameProfile = null;
|
2016-05-12 13:30:22 +02:00
|
|
|
}
|
2016-11-30 05:08:12 +01:00
|
|
|
else {
|
|
|
|
if (newSkin.length() > 16) {
|
2016-06-14 11:08:53 +02:00
|
|
|
skinToUse = newSkin.substring(0, 16);
|
2015-03-10 01:28:41 +01:00
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
currentLookup = new LibsProfileLookup() {
|
2016-06-14 11:08:53 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public void onLookup(WrappedGameProfile gameProfile) {
|
2016-06-14 11:08:53 +02:00
|
|
|
if (currentLookup != this || gameProfile == null)
|
|
|
|
return;
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
setSkin(gameProfile);
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-06-14 11:08:53 +02:00
|
|
|
currentLookup = null;
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
2016-06-14 11:08:53 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
WrappedGameProfile gameProfile = DisguiseUtilities.getProfileFromMojang(this.skinToUse, currentLookup,
|
|
|
|
LibsDisguises.getInstance().getConfig().getBoolean("ContactMojangServers", true));
|
|
|
|
|
2016-11-30 05:08:12 +01:00
|
|
|
if (gameProfile != null) {
|
2016-06-14 11:08:53 +02:00
|
|
|
setSkin(gameProfile);
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2014-07-11 06:37:34 +02:00
|
|
|
return this;
|
2014-05-31 20:47:05 +02:00
|
|
|
}
|
|
|
|
|
2014-06-05 14:08:54 +02:00
|
|
|
/**
|
|
|
|
* Set the GameProfile, without tampering.
|
2015-08-03 00:39:44 +02:00
|
|
|
*
|
2016-05-12 13:30:22 +02:00
|
|
|
* @param gameProfile
|
|
|
|
* GameProfile
|
2014-07-11 07:07:47 +02:00
|
|
|
* @return
|
2014-06-05 14:08:54 +02:00
|
|
|
*/
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setSkin(WrappedGameProfile gameProfile) {
|
|
|
|
if (gameProfile == null) {
|
2014-06-05 14:08:54 +02:00
|
|
|
this.gameProfile = null;
|
|
|
|
this.skinToUse = null;
|
2014-07-11 06:37:53 +02:00
|
|
|
return this;
|
2014-06-05 14:08:54 +02:00
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2016-06-14 20:40:45 +02:00
|
|
|
Validate.notEmpty(gameProfile.getName(), "Name must be set");
|
|
|
|
|
|
|
|
currentLookup = null;
|
2016-06-14 11:08:53 +02:00
|
|
|
|
2016-06-14 20:40:45 +02:00
|
|
|
this.skinToUse = gameProfile.getName();
|
2016-11-30 05:08:12 +01:00
|
|
|
this.gameProfile = ReflectionManager.getGameProfileWithThisSkin(uuid, getName(), gameProfile);
|
|
|
|
|
|
|
|
if (DisguiseUtilities.isDisguiseInUse(this)) {
|
|
|
|
if (isDisplayedInTab()) {
|
|
|
|
PacketContainer addTab = new PacketContainer(PacketType.Play.Server.PLAYER_INFO);
|
|
|
|
addTab.getPlayerInfoAction().write(0, PlayerInfoAction.ADD_PLAYER);
|
|
|
|
addTab.getPlayerInfoDataLists().write(0, Arrays.asList(new PlayerInfoData(getGameProfile(), 0,
|
|
|
|
NativeGameMode.SURVIVAL, WrappedChatComponent.fromText(getName()))));
|
|
|
|
|
|
|
|
PacketContainer deleteTab = addTab.shallowClone();
|
|
|
|
deleteTab.getPlayerInfoAction().write(0, PlayerInfoAction.REMOVE_PLAYER);
|
|
|
|
|
|
|
|
try {
|
|
|
|
for (Player player : Bukkit.getOnlinePlayers()) {
|
|
|
|
if (!((TargetedDisguise) this).canSee(player))
|
|
|
|
continue;
|
|
|
|
|
|
|
|
ProtocolLibrary.getProtocolManager().sendServerPacket(player, deleteTab);
|
|
|
|
ProtocolLibrary.getProtocolManager().sendServerPacket(player, addTab);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (InvocationTargetException e) {
|
|
|
|
e.printStackTrace();
|
|
|
|
}
|
|
|
|
}
|
2016-06-14 20:40:45 +02:00
|
|
|
|
|
|
|
DisguiseUtilities.refreshTrackers(this);
|
2015-03-30 04:47:29 +02:00
|
|
|
}
|
2016-05-12 13:30:22 +02:00
|
|
|
|
2014-07-11 06:37:34 +02:00
|
|
|
return this;
|
2014-06-05 14:08:54 +02:00
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setVelocitySent(boolean sendVelocity) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setVelocitySent(sendVelocity);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setViewSelfDisguise(boolean viewSelfDisguise) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setViewSelfDisguise(viewSelfDisguise);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise setWatcher(FlagWatcher newWatcher) {
|
2014-07-11 07:07:47 +02:00
|
|
|
return (PlayerDisguise) super.setWatcher(newWatcher);
|
|
|
|
}
|
2014-07-11 07:16:19 +02:00
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise silentlyAddPlayer(String playername) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.silentlyAddPlayer(playername);
|
|
|
|
}
|
|
|
|
|
2015-05-30 15:34:38 +02:00
|
|
|
@Override
|
2016-11-30 05:08:12 +01:00
|
|
|
public PlayerDisguise silentlyRemovePlayer(String playername) {
|
2014-07-11 07:16:19 +02:00
|
|
|
return (PlayerDisguise) super.silentlyRemovePlayer(playername);
|
|
|
|
}
|
2015-03-29 00:05:53 +01:00
|
|
|
}
|