Enum Class ThermooSeasons

java.lang.Object
java.lang.Enum<ThermooSeasons>
com.github.thedeathlycow.thermoo.api.season.ThermooSeasons
All Implemented Interfaces:
Serializable, Comparable<ThermooSeasons>, Constable

public enum ThermooSeasons extends Enum<ThermooSeasons>
Mod-agnostic Seasons enum. Thermoo does not provide seasons itself, but this can be used to better integrate with any mods that do provide seasons.
  • Enum Constant Details

  • Method Details

    • values

      public static ThermooSeasons[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ThermooSeasons valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getCurrentSeason

      public static Optional<ThermooSeasons> getCurrentSeason(net.minecraft.world.World world)
      Shorthand for invoking ThermooSeasonEvents.GET_CURRENT_SEASON.

      Retrieves the current season, if a season mod is loaded. Thermoo does not add seasons by itself, seasons must be implemented by another mod like Fabric Seasons or Serene Seasons. This event just places season integration into a common source.

      Parameters:
      world - The current world / level to get the season from.
      Returns:
      Returns the current season if a Seasons mod is installed, or empty if no seasons mod is installed.