Class UtilEnvironment

java.lang.Object
net.lewmc.essence.environment.UtilEnvironment

public class UtilEnvironment extends Object
The environment utility.
  • Constructor Details

    • UtilEnvironment

      public UtilEnvironment()
  • Method Details

    • getWeather

      public UtilEnvironment.Weather getWeather(org.bukkit.World w)
      Gets the weather of the requested world.
      Parameters:
      w - World - The world requested.
      Returns:
      Weather - The active weather type.
    • setWeather

      public boolean setWeather(org.bukkit.World wo, UtilEnvironment.Weather we)
      Sets the weather in the requested world
      Parameters:
      wo - World - The world
      we - Weather - The weather
      Returns:
      boolean - Success?
    • getPlayerWeather

      public UtilEnvironment.Weather getPlayerWeather(org.bukkit.entity.Player p)
      Gets the weather of the requested player.
      Parameters:
      p - Player - The player requested.
      Returns:
      Weather - The active weather type.
    • setPlayerWeather

      public boolean setPlayerWeather(org.bukkit.entity.Player p, UtilEnvironment.Weather we)
      Sets the weather in the requested world
      Parameters:
      p - Player - The player
      we - 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

      public boolean setTime(org.bukkit.World wo, UtilEnvironment.Time t)
      Sets the time in the requested world
      Parameters:
      wo - World - The world
      t - 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 world
      t - 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

      public boolean setPlayerTime(org.bukkit.entity.Player p, UtilEnvironment.Time t)
      Sets the time of the requested player
      Parameters:
      p - Player - The player
      t - 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 player
      t - long - The numeric time
      Returns:
      boolean - Success?