Class GDPlayerData
java.lang.Object
me.EtienneDx.RealEstate.ClaimAPI.GriefDefender.GDPlayerData
- All Implemented Interfaces:
IPlayerData
GDPlayerData is an implementation of the
IPlayerData
interface for GriefDefender.
It wraps a GriefDefender PlayerData
instance to provide player claim block information.-
Constructor Summary
ConstructorsConstructorDescriptionGDPlayerData
(com.griefdefender.api.data.PlayerData playerData) Constructs a new GDPlayerData instance using the specified PlayerData. -
Method Summary
Modifier and TypeMethodDescriptionint
Retrieves the number of accrued claim blocks for the player.int
Retrieves the number of bonus claim blocks for the player.int
Retrieves the number of remaining claim blocks available to the player.void
setAccruedClaimBlocks
(int accruedClaimBlocks) Sets the number of accrued claim blocks for the player.void
setBonusClaimBlocks
(int bonusClaimBlocks) Sets the number of bonus claim blocks for the player.
-
Constructor Details
-
GDPlayerData
public GDPlayerData(com.griefdefender.api.data.PlayerData playerData) Constructs a new GDPlayerData instance using the specified PlayerData.- Parameters:
playerData
- the GriefDefender PlayerData instance to wrap
-
-
Method Details
-
getAccruedClaimBlocks
public int getAccruedClaimBlocks()Retrieves the number of accrued claim blocks for the player.- Specified by:
getAccruedClaimBlocks
in interfaceIPlayerData
- Returns:
- the number of accrued claim blocks
-
getBonusClaimBlocks
public int getBonusClaimBlocks()Retrieves the number of bonus claim blocks for the player.- Specified by:
getBonusClaimBlocks
in interfaceIPlayerData
- Returns:
- the number of bonus claim blocks
-
setAccruedClaimBlocks
public void setAccruedClaimBlocks(int accruedClaimBlocks) Sets the number of accrued claim blocks for the player.- Specified by:
setAccruedClaimBlocks
in interfaceIPlayerData
- Parameters:
accruedClaimBlocks
- the new number of accrued claim blocks
-
setBonusClaimBlocks
public void setBonusClaimBlocks(int bonusClaimBlocks) Sets the number of bonus claim blocks for the player.- Specified by:
setBonusClaimBlocks
in interfaceIPlayerData
- Parameters:
bonusClaimBlocks
- the new number of bonus claim blocks
-
getRemainingClaimBlocks
public int getRemainingClaimBlocks()Retrieves the number of remaining claim blocks available to the player.- Specified by:
getRemainingClaimBlocks
in interfaceIPlayerData
- Returns:
- the number of remaining claim blocks
-