public interface LocalPlayer extends com.sk89q.worldedit.entity.Player, RegionAssociable
| Modifier and Type | Method and Description |
|---|---|
void |
ban(java.lang.String msg)
Ban this player.
|
default Association |
getAssociation(java.util.List<ProtectedRegion> regions)
Get the highest association level for the input regions.
|
float |
getExhaustion()
Gets the exhaustion of this player.
|
int |
getFireTicks()
Gets the number of ticks the player is on fire for.
|
double |
getFoodLevel()
Gets the food level of this player.
|
double |
getHealth()
Gets the health of this player.
|
double |
getMaxHealth()
Gets the max health of this player.
|
long |
getPlayerTimeOffset()
Gets the time offset of the player.
|
com.sk89q.worldedit.world.weather.WeatherType |
getPlayerWeather()
Gets the players weather
|
double |
getSaturation()
Gets the saturation of this player.
|
boolean |
hasGroup(java.lang.String group)
Returns true if this player is inside a group.
|
boolean |
isPlayerTimeRelative()
Gets if the players time is relative.
|
void |
kick(java.lang.String msg)
Kick this player.
|
void |
resetFallDistance()
Clears fall distance.
|
void |
resetPlayerTime()
Resets the players time to normal.
|
void |
resetPlayerWeather()
Resets the players weather to normal.
|
void |
sendTitle(java.lang.String title,
java.lang.String subtitle)
This should preferably take Components but there's no way to do that yet
|
void |
setCompassTarget(com.sk89q.worldedit.util.Location location)
Sets the target of the compass
|
void |
setExhaustion(float exhaustion)
Sets the exhaustion of this player.
|
void |
setFireTicks(int fireTicks)
Sets the number of ticks the player is on fire for.
|
void |
setFoodLevel(double foodLevel)
Sets the food level of this player.
|
void |
setHealth(double health)
Sets the health of this player.
|
void |
setPlayerTime(long time,
boolean relative)
Sets the players time.
|
void |
setPlayerWeather(com.sk89q.worldedit.world.weather.WeatherType weather)
Sets the players WeatherType
|
void |
setSaturation(double saturation)
Sets the saturation of this player.
|
void |
teleport(com.sk89q.worldedit.util.Location location,
java.lang.String successMessage,
java.lang.String failMessage)
Teleport the player, potentially async, displaying the message on a success.
|
ascendLevel, ascendToCeiling, ascendToCeiling, ascendUpwards, ascendUpwards, descendLevel, findFreePosition, findFreePosition, floatAt, getBlockIn, getBlockInHand, getBlockOn, getBlockTrace, getBlockTrace, getBlockTrace, getBlockTraceFace, getBlockTraceFace, getCardinalDirection, getCardinalDirection, getGameMode, getInventoryBlockBag, getItemInHand, getSolidBlockTrace, getWorld, giveItem, isHoldingPickAxe, passThroughForwardWall, sendFakeBlock, setGameMode, setOnGround, setPosition, setPositiongetExtent, getLocation, getState, remove, setLocationboolean hasGroup(java.lang.String group)
group - The group to checkgroupvoid kick(java.lang.String msg)
msg - The message to kick the player withvoid ban(java.lang.String msg)
msg - The message to ban the player withdefault Association getAssociation(java.util.List<ProtectedRegion> regions)
RegionAssociablegetAssociation in interface RegionAssociableregions - a list of regionsdouble getHealth()
void setHealth(double health)
health - The healthdouble getMaxHealth()
double getFoodLevel()
void setFoodLevel(double foodLevel)
foodLevel - The food leveldouble getSaturation()
void setSaturation(double saturation)
saturation - The saturationfloat getExhaustion()
void setExhaustion(float exhaustion)
exhaustion - The exhaustioncom.sk89q.worldedit.world.weather.WeatherType getPlayerWeather()
void setPlayerWeather(com.sk89q.worldedit.world.weather.WeatherType weather)
weather - The weather typevoid resetPlayerWeather()
boolean isPlayerTimeRelative()
long getPlayerTimeOffset()
void setPlayerTime(long time,
boolean relative)
time - The players timerelative - If it's relativevoid resetPlayerTime()
int getFireTicks()
void setFireTicks(int fireTicks)
fireTicks - The fire ticksvoid setCompassTarget(com.sk89q.worldedit.util.Location location)
location - The location@Beta
void sendTitle(java.lang.String title,
java.lang.String subtitle)
title - the title to displaysubtitle - the subtitle to displayvoid resetFallDistance()
void teleport(com.sk89q.worldedit.util.Location location,
java.lang.String successMessage,
java.lang.String failMessage)
location - location to teleport tosuccessMessage - message to display on successfailMessage - message to display on failure