Package me.neznamy.tab.shared.proxy
Class ProxyTabPlayer
java.lang.Object
me.neznamy.tab.shared.ITabPlayer
me.neznamy.tab.shared.proxy.ProxyTabPlayer
- All Implemented Interfaces:
me.neznamy.tab.api.TabPlayer
Abstract class for player on proxy containing variables and methods
shared between proxies.
-
Field Summary
Fields inherited from class me.neznamy.tab.shared.ITabPlayer
channel, player, version -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedProxyTabPlayer(Object player, UUID uniqueId, String name, String server, int protocolVersion) Constructs new instance with given parameters and sends a message to bridge about this player joining with join data -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanhasPermission(String permission) abstract booleanhasPermission0(String permission) Performs platform-specific permission check and returns the resultbooleanbooleanisOnBoat()Returnstrueif player is on boat,falseif not.booleanvoidSends plugin message to backend server that this player has joined, containing all plugin configuration data.abstract voidsendPluginMessage(byte[] message) Sends plugin message to this playervoidsetDisguised(boolean disguised) Sets disguise status to provided valuevoidsetHasPermission(String permission, boolean value) Sets permission presence status to provided valuevoidsetInvisible(boolean invisible) Sets invisibility status to provided valuevoidsetOnBoat(boolean onBoat) Sets boat status to provided valuevoidsetVanished(boolean vanished) Sets vanish status to provided valueMethods inherited from class me.neznamy.tab.shared.ITabPlayer
clearRegisteredObjectives, forceRefresh, getChannel, getGroup, getName, getNickname, getProperty, getServer, getTablistUUID, getTeamName, getTeamNameNote, getUniqueId, getVersion, getWorld, hasTemporaryGroup, isBedrockPlayer, isLoaded, loadPropertyFromConfig, loadPropertyFromConfig, markAsLoaded, resetTemporaryGroup, sendCustomPacket, sendCustomPacket, sendCustomPacket, sendMessage, sendMessage, setGroup, setNickname, setProperty, setServer, setTeamName, setTeamNameNote, setTemporaryGroup, setWorldMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface me.neznamy.tab.api.TabPlayer
getGamemode, getPing, getPlayer, getSkin, isOnline, sendPacket
-
Constructor Details
-
ProxyTabPlayer
protected ProxyTabPlayer(Object player, UUID uniqueId, String name, String server, int protocolVersion) Constructs new instance with given parameters and sends a message to bridge about this player joining with join data- Parameters:
player- platform-specific player objectuniqueId- Player's unique IDname- Player's nameserver- Player's serverprotocolVersion- Player's protocol network id
-
-
Method Details
-
sendJoinPluginMessage
public void sendJoinPluginMessage()Sends plugin message to backend server that this player has joined, containing all plugin configuration data. -
setVanished
public void setVanished(boolean vanished) Sets vanish status to provided value- Parameters:
vanished- new vanish status
-
setDisguised
public void setDisguised(boolean disguised) Sets disguise status to provided value- Parameters:
disguised- new disguise status
-
setInvisible
public void setInvisible(boolean invisible) Sets invisibility status to provided value- Parameters:
invisible- new invisibility status
-
setOnBoat
public void setOnBoat(boolean onBoat) Sets boat status to provided value- Parameters:
onBoat- new boat status
-
setHasPermission
Sets permission presence status to provided value- Parameters:
permission- Requested permission nodevalue- Permission value
-
isOnBoat
public boolean isOnBoat()Returnstrueif player is on boat,falseif not. This requires bridge installed to forward the data.- Returns:
trueif on boat,falseif not
-
hasPermission0
Performs platform-specific permission check and returns the result- Parameters:
permission- Permission to check for- Returns:
- Result from hasPermission call
-
sendPluginMessage
public abstract void sendPluginMessage(byte[] message) Sends plugin message to this player- Parameters:
message- message to send
-
isVanished
public boolean isVanished() -
isDisguised
public boolean isDisguised() -
hasInvisibilityPotion
public boolean hasInvisibilityPotion() -
hasPermission
-