Package net.fateuhc.plugin.api.managers
Class ProfileManager
java.lang.Object
net.fateuhc.plugin.api.managers.ProfileManager
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanSpectate(org.bukkit.entity.Player player) Used to check a player's spectating status.List<org.bukkit.entity.Player> getPlayersInState(PlayerState playerState) Used to gather the users in a PlayerState.getProfile(Object object) Used to get a player's profile.Used to get the list of profiles.intgetSpectatorRadius(org.bukkit.entity.Player player) Used to check a player's spectating radius.voidhandleProfileCreation(UUID uuid, String name) Deprecated.This will be removed in a future api version as it should be an internal method.booleanisHost(org.bukkit.entity.Player player) Used to see if a player is the host.booleanisSpectator(org.bukkit.entity.Player player) Used to see if a player is a spectator.voidsetProfiles(Map<UUID, Profile> profiles) Used to set the list of profiles.voidsetSpectating(org.bukkit.entity.Player player, Profile profile) Used to set a player to spectator mode.
-
Constructor Details
-
ProfileManager
public ProfileManager()
-
-
Method Details
-
handleProfileCreation
Deprecated.This will be removed in a future api version as it should be an internal method.Used to create a player's profile. This is done on the first join of the player.- Parameters:
uuid- Player's UUIDname- Player's name
-
getProfile
Used to get a player's profile.- Parameters:
object- Player's UUID or Name- Returns:
- Player's profile
-
canSpectate
public boolean canSpectate(org.bukkit.entity.Player player) Used to check a player's spectating status.- Parameters:
player- Player's name- Returns:
- True/False if the player can spectate
-
getSpectatorRadius
public int getSpectatorRadius(org.bukkit.entity.Player player) Used to check a player's spectating radius.- Parameters:
player- Player's Name- Returns:
- Current player's spectator radius
-
getPlayersInState
Used to gather the users in a PlayerState.- Parameters:
playerState- Designate the PlayerState- Returns:
- List of players in the designated PlayerState
-
isSpectator
public boolean isSpectator(org.bukkit.entity.Player player) Used to see if a player is a spectator.- Parameters:
player- Player's name- Returns:
- True/False based upon if the player is spectating
-
isHost
public boolean isHost(org.bukkit.entity.Player player) Used to see if a player is the host.- Parameters:
player- PLayer's name- Returns:
- True/False if the player is the host of the game
-
setSpectating
Used to set a player to spectator mode.- Parameters:
player- Player's nameprofile- Player's profile
-
getProfiles
Used to get the list of profiles.- Returns:
- List of profiles
-
setProfiles
Used to set the list of profiles.- Parameters:
profiles- List of profiles
-