Package sawfowl.commandpack.api
Interface TempPlayerData
public interface TempPlayerData
Used to store temporary data of players who used the functionality of the CommandPack plugin.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddCommandTracking(String command, ServerPlayer player) Adding command usage tracking.
Only CommandPack plugin API commands are accepted.voidaddReply(ServerPlayer player, Audience audience) Adding Audience for the /reply commandvoidaddTrackingCooldownCommand(String command) Register the tracking of delays between command executions.voidaddTrackingCooldownCommand(PluginCommand command) Register the tracking of delays between command executions.longgetLastActivity(ServerPlayer player) Getting the time of the last activity of the player.getPlayerMods(ServerPlayer player) Deprecated.getPreviousLocation(ServerPlayer player) Getting the player's location before teleportation.getReply(ServerPlayer player) Getting Audience for the /reply commandgetTrackingMap(String command) A map of players who cannot currently reuse a command.getTrackingMap(PluginCommand command) A map of players who cannot currently reuse a command.Getting a tracking map of waiting execute player commands.
Changing this map has no effect on the tracking.Getting a tracking map of waiting execute player commands.
Changing this map has no effect on the tracking.getVanishEnabledTime(ServerPlayer player) The invisibility activation time with the `/vanish` command.booleanisAfk(ServerPlayer player) Checks the status of the player's current activity.booleanisDisableTpRequests(ServerPlayer player) Whether the player accepts teleportation requests.booleanisSpyCommand(ServerPlayer player) Whether the player listens to other players' commands.booleanisTrackingPlayer(UUID uuid) Tracking check.booleanisTrackingPlayer(ServerPlayer player) Tracking check.booleanisVanished(ServerPlayer player) If true, the player is invisible and will be shown as offline in the `/seen` command.
In this case, the time of the last activity will be equal to the activation time of invisibility.voidregisterCommandTracking(PluginCommand command) Registering to track a command.voidremoveCommandTracking(String command, UUID uuid) Removing command usage tracking.
Only CommandPack plugin commands are accepted.
If you remove the tracking of a command to be executed by the player when the timer expires, it will not be executed.voidremoveCommandTracking(String command, ServerPlayer player) Removing command usage tracking.
Only CommandPack plugin commands are accepted.
If you remove the tracking of a command to be executed by the player when the timer expires, it will not be executed.voidremoveReply(ServerPlayer player) Removing Audience for the /reply commandvoidremoveVanishEnabledTime(ServerPlayer player) Removing the invisibility activation time.voidsetAfkStatus(ServerPlayer player) Assigning AFK status to a player.voidsetPreviousLocation(ServerPlayer player) Set the location of the player's previous location.voidsetVanishTime(ServerPlayer player) Specify the current time as the activation time of invisibility in the player.voidswitchSpyCommand(ServerPlayer player) Switching the player's status of listening to the commands of other players.
A player will not be added if he does not have permission to listen to commands.voidtpToggle(ServerPlayer player) Change the status of receiving teleportation requests.voidupdateLastActivity(ServerPlayer player) Updating the time of the player's last activity
-
Method Details
-
registerCommandTracking
Registering to track a command. -
addCommandTracking
Adding command usage tracking.
Only CommandPack plugin API commands are accepted.- Parameters:
command- - Settings or alias.player- - The player.
-
isTrackingPlayer
Tracking check.- Parameters:
player- - The player.- Returns:
- If true, then the plugin monitors the execution of any command by the player.
-
isTrackingPlayer
Tracking check.- Parameters:
uuid- - The player uuidUUID- Returns:
- If true, then the plugin monitors the execution of any command by the player.
-
removeCommandTracking
Removing command usage tracking.
Only CommandPack plugin commands are accepted.
If you remove the tracking of a command to be executed by the player when the timer expires, it will not be executed.- Parameters:
command- - PluginCommand or alias.player- - The player.
-
removeCommandTracking
Removing command usage tracking.
Only CommandPack plugin commands are accepted.
If you remove the tracking of a command to be executed by the player when the timer expires, it will not be executed.- Parameters:
command- - PluginCommand or alias.uuid- - The player uuid.
-
getTrackingPlayerCommands
Getting a tracking map of waiting execute player commands.
Changing this map has no effect on the tracking. -
getTrackingPlayerCommands
Getting a tracking map of waiting execute player commands.
Changing this map has no effect on the tracking. -
tpToggle
Change the status of receiving teleportation requests. -
isDisableTpRequests
Whether the player accepts teleportation requests. -
getPreviousLocation
Getting the player's location before teleportation. -
setPreviousLocation
Set the location of the player's previous location. -
addTrackingCooldownCommand
Register the tracking of delays between command executions. -
addTrackingCooldownCommand
Register the tracking of delays between command executions. -
getTrackingMap
A map of players who cannot currently reuse a command. -
getTrackingMap
A map of players who cannot currently reuse a command. -
updateLastActivity
Updating the time of the player's last activity -
getLastActivity
Getting the time of the last activity of the player. -
isAfk
Checks the status of the player's current activity.- Returns:
- If false, then the player was recently active.
If true, then the time has passed since the last activity of the player specified in the configuration of the plugin.
-
setAfkStatus
Assigning AFK status to a player. -
switchSpyCommand
Switching the player's status of listening to the commands of other players.
A player will not be added if he does not have permission to listen to commands. -
isSpyCommand
Whether the player listens to other players' commands. -
setVanishTime
Specify the current time as the activation time of invisibility in the player. -
isVanished
If true, the player is invisible and will be shown as offline in the `/seen` command.
In this case, the time of the last activity will be equal to the activation time of invisibility. -
getVanishEnabledTime
The invisibility activation time with the `/vanish` command. -
removeVanishEnabledTime
Removing the invisibility activation time. -
addReply
Adding Audience for the /reply command -
removeReply
Removing Audience for the /reply command -
getReply
Getting Audience for the /reply command -
getPlayerMods
Deprecated.
-