Package net.lewmc.essence.environment
Class UtilEnvironment
java.lang.Object
net.lewmc.essence.environment.UtilEnvironment
The environment utility.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Stores preset timesstatic enum
Stores preset weather. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlong
getPlayerTime
(org.bukkit.entity.Player p) Gets the time of the requested player.getPlayerWeather
(org.bukkit.entity.Player p) Gets the weather of the requested player.long
getTime
(org.bukkit.World w) Gets the time of the requested world.getWeather
(org.bukkit.World w) Gets the weather of the requested world.boolean
setPlayerTime
(org.bukkit.entity.Player p, long t) Sets the time of the requested playerboolean
setPlayerTime
(org.bukkit.entity.Player p, UtilEnvironment.Time t) Sets the time of the requested playerboolean
setPlayerWeather
(org.bukkit.entity.Player p, UtilEnvironment.Weather we) Sets the weather in the requested worldboolean
setTime
(org.bukkit.World wo, long t) Sets the time in the requested worldboolean
setTime
(org.bukkit.World wo, UtilEnvironment.Time t) Sets the time in the requested worldboolean
setWeather
(org.bukkit.World wo, UtilEnvironment.Weather we) Sets the weather in the requested world
-
Constructor Details
-
UtilEnvironment
public UtilEnvironment()
-
-
Method Details
-
getWeather
Gets the weather of the requested world.- Parameters:
w
- World - The world requested.- Returns:
- Weather - The active weather type.
-
setWeather
Sets the weather in the requested world- Parameters:
wo
- World - The worldwe
- Weather - The weather- Returns:
- boolean - Success?
-
getPlayerWeather
Gets the weather of the requested player.- Parameters:
p
- Player - The player requested.- Returns:
- Weather - The active weather type.
-
setPlayerWeather
Sets the weather in the requested world- Parameters:
p
- Player - The playerwe
- Weather - The weather- Returns:
- boolean - Success?
-
getTime
public long getTime(org.bukkit.World w) Gets the time of the requested world.- Parameters:
w
- World - The world requested.- Returns:
- long - The time.
-
setTime
Sets the time in the requested world- Parameters:
wo
- World - The worldt
- Time - The preset time- Returns:
- boolean - Success?
-
setTime
public boolean setTime(org.bukkit.World wo, long t) Sets the time in the requested world- Parameters:
wo
- World - The worldt
- long - The numeric time- Returns:
- boolean - Success?
-
getPlayerTime
public long getPlayerTime(org.bukkit.entity.Player p) Gets the time of the requested player.- Parameters:
p
- Player - The player requested.- Returns:
- long - The player time.
-
setPlayerTime
Sets the time of the requested player- Parameters:
p
- Player - The playert
- Time - The preset time- Returns:
- boolean - Success?
-
setPlayerTime
public boolean setPlayerTime(org.bukkit.entity.Player p, long t) Sets the time of the requested player- Parameters:
p
- Player - The playert
- long - The numeric time- Returns:
- boolean - Success?
-