Various code simplification/fixes and a lot of typo/grammar fixes (may brake some stuff)
This commit is contained in:
@@ -29,7 +29,7 @@ public interface AbstractOffPlayer {
|
||||
|
||||
/**
|
||||
* Indicate if this player is connected to the current node (server or proxy, depending on interface implementation).
|
||||
* @return wether the player is online or not.
|
||||
* @return weather the player is online or not.
|
||||
*/
|
||||
boolean isOnline();
|
||||
|
||||
|
@@ -53,7 +53,7 @@ public interface AbstractOnlinePlayer extends AbstractOffPlayer {
|
||||
/**
|
||||
* Tells if this online player has the specified permission.
|
||||
* @param permission the permission to test on that player.
|
||||
* @return weither this player has the specified permission or not.
|
||||
* @return weather this player has the specified permission or not.
|
||||
* @implSpec Implementation of this method should call the permission system of their environment (paper/bungee),
|
||||
* so this method will work independently of the usage of the 'pandalib-permissions' module.
|
||||
*/
|
||||
@@ -90,7 +90,7 @@ public interface AbstractOnlinePlayer extends AbstractOffPlayer {
|
||||
* <p>
|
||||
* This method differs from {@link #sendMessage(ComponentLike)} with the fact that this method sends the message
|
||||
* only if {@link #canChat()} returns true.
|
||||
* The message sent to the client is still a SYSTEM messge, due to CHAT messages required to be signed.
|
||||
* The message sent to the client is still a SYSTEM message, due to CHAT messages required to be signed.
|
||||
* @param message the message to display as CHAT message.
|
||||
*/
|
||||
default void sendChatMessage(ComponentLike message) {
|
||||
@@ -203,13 +203,13 @@ public interface AbstractOnlinePlayer extends AbstractOffPlayer {
|
||||
|
||||
/**
|
||||
* Tells if the client has configured the main hand on the left.
|
||||
* @return true if the player’s character is left handed, false otherwise.
|
||||
* @return true if the player’s character is left-handed, false otherwise.
|
||||
*/
|
||||
boolean isLeftHanded();
|
||||
|
||||
/**
|
||||
* Tells if the client has configured the main hand on the right.
|
||||
* @return true if the player’s character is right handed, false otherwise.
|
||||
* @return true if the player’s character is right-handed, false otherwise.
|
||||
*/
|
||||
boolean isRightHanded();
|
||||
|
||||
@@ -279,8 +279,8 @@ public interface AbstractOnlinePlayer extends AbstractOffPlayer {
|
||||
* Tells if the player can send chat messages or receive chat messages from other players, according to their client
|
||||
* configuration.
|
||||
* <p>
|
||||
* Chat messages represent public communication between players. By default, it only include actual chat message.
|
||||
* This method may be used in commands like /me, /afk or the login/logout broadcasted messages.
|
||||
* Chat messages represent public communication between players. By default, it only includes actual chat message.
|
||||
* This method may be used in commands like /me, /afk or the login/logout broadcast messages.
|
||||
* @return true if the player can send chat messages or receive chat messages from other players, false otherwise.
|
||||
*/
|
||||
default boolean canChat() {
|
||||
|
@@ -258,7 +258,7 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
* @param prefix if the server prefix will be prepended to the message.
|
||||
* @param console if the message must be displayed in the console.
|
||||
* @param permission if not null, the message is only sent to player with this permission.
|
||||
* @param sourcePlayer specifiy the eventual player that is the source of the message.
|
||||
* @param sourcePlayer specify the eventual player that is the source of the message.
|
||||
* If null, the message will be sent as a SYSTEM chat message.
|
||||
* If not null, the message will be sent as a CHAT message, and will not be sent
|
||||
* to players ignoring the provided player (if implemented).
|
||||
@@ -315,7 +315,7 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
* @param prefix if the server prefix will be prepended to the message.
|
||||
* @param permission if not null, the message is only sent to player with this permission (but not to console).
|
||||
* If null, the message will be sent to all players and to console.
|
||||
* @param sourcePlayer specifiy the eventual player that is the source of the message.
|
||||
* @param sourcePlayer specify the eventual player that is the source of the message.
|
||||
* If null, the message will be sent as a SYSTEM chat message.
|
||||
* If not null, the message will be sent as a CHAT message, and will not be sent
|
||||
* to players ignoring the provided player (if implemented).
|
||||
@@ -330,13 +330,13 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
/**
|
||||
* Broadcast a message to some or all players, and eventually to the console.
|
||||
* <p>
|
||||
* This method doesn’t restrict to a specific permission. To change this behaviour, use
|
||||
* This method doesn't restrict to a specific permission. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, boolean, String, UUID)}.
|
||||
*
|
||||
* @param message the message to send.
|
||||
* @param prefix if the server prefix will be prepended to the message.
|
||||
* @param console if the message must be displayed in the console.
|
||||
* @param sourcePlayer specifiy the eventual player that is the source of the message.
|
||||
* @param sourcePlayer specify the eventual player that is the source of the message.
|
||||
* If null, the message will be sent as a SYSTEM chat message.
|
||||
* If not null, the message will be sent as a CHAT message, and will not be sent
|
||||
* to players ignoring the provided player (if implemented).
|
||||
@@ -354,7 +354,7 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
* This method assumes this message is not caused by a specific player. To specify the source player, use
|
||||
* {@link #broadcast(ComponentLike, boolean, boolean, UUID)}.
|
||||
* <p>
|
||||
* This method doesn’t restrict to a specific permission. To change this behaviour, use
|
||||
* This method doesn't restrict to a specific permission. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, boolean, String)}.
|
||||
*
|
||||
* @param message the message to send.
|
||||
@@ -372,12 +372,12 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
* This method sends the message to the console. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, boolean, UUID)}.
|
||||
* <p>
|
||||
* This method doesn’t restrict to a specific permission. To change this behaviour, use
|
||||
* This method doesn't restrict to a specific permission. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, String, UUID)}.
|
||||
*
|
||||
* @param message the message to send.
|
||||
* @param prefix if the server prefix will be prepended to the message.
|
||||
* @param sourcePlayer specifiy the eventual player that is the source of the message.
|
||||
* @param sourcePlayer specify the eventual player that is the source of the message.
|
||||
* If null, the message will be sent as a SYSTEM chat message.
|
||||
* If not null, the message will be sent as a CHAT message, and will not be sent
|
||||
* to players ignoring the provided player (if implemented).
|
||||
@@ -396,7 +396,7 @@ public abstract class AbstractPlayerManager<OP extends AbstractOnlinePlayer, OF
|
||||
* This method sends the message to the console. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, boolean)}.
|
||||
* <p>
|
||||
* This method doesn’t restrict to a specific permission. To change this behaviour, use
|
||||
* This method doesn't restrict to a specific permission. To change this behaviour, use
|
||||
* {@link #broadcast(ComponentLike, boolean, String)}.
|
||||
*
|
||||
* @param message the message to send.
|
||||
|
Reference in New Issue
Block a user