Package net.crux.ac.api.data
Interface CruxPlayer
public interface CruxPlayer
Safe, read-only wrapper representing a player monitored by CruxAC.
-
Method Summary
Modifier and TypeMethodDescriptionorg.bukkit.entity.PlayerAssociated Bukkit Player instance (or null if offline).getName()Player name.intgetPing()Average ping of the player in milliseconds.Client platform type (JAVA or BEDROCK).doubleGets the cumulative violation level across all active checks.doubleGets the dynamic trust score of the player [0.0 - 1.0].Unique identifier of the player.doubleGets the current Violation Level (VL) for a specific check.booleanWhether the player joined via Bedrock (Geyser/Floodgate).voidResets all violation levels for this player.voidResets the violation level for a specific check.
-
Method Details
-
getUniqueId
UUID getUniqueId()Unique identifier of the player. -
getName
String getName()Player name. -
getBukkitPlayer
org.bukkit.entity.Player getBukkitPlayer()Associated Bukkit Player instance (or null if offline). -
isBedrock
boolean isBedrock()Whether the player joined via Bedrock (Geyser/Floodgate). -
getPlatform
PlatformType getPlatform()Client platform type (JAVA or BEDROCK). -
getPing
int getPing()Average ping of the player in milliseconds. -
getVl
Gets the current Violation Level (VL) for a specific check.- Parameters:
checkName- Name of the check (e.g. "Flight", "Speed", "Step")- Returns:
- Current violation level
-
getTotalVl
double getTotalVl()Gets the cumulative violation level across all active checks. -
getTrustScore
double getTrustScore()Gets the dynamic trust score of the player [0.0 - 1.0]. Higher score indicates trustworthy vanilla client behavior. -
resetVl
Resets the violation level for a specific check. -
resetAllVl
void resetAllVl()Resets all violation levels for this player.
-