Enum Class BattleSceneWeather
- All Implemented Interfaces:
Serializable,Comparable<BattleSceneWeather>,Constable
Fixed weather states that can be authored for a battle scene.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic BattleSceneWeatherdecode(net.minecraft.network.FriendlyByteBuf buffer) Decodes a weather state from a battle scene packet.voidencode(net.minecraft.network.FriendlyByteBuf buffer) Encodes this weather state for a battle scene packet.floatfloatstatic BattleSceneWeatherReturns the enum constant of this class with the specified name.static BattleSceneWeather[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
CLEAR
-
RAIN
-
THUNDER
-
-
Field Details
-
CODEC
-
-
Method Details
-
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
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 nameNullPointerException- if the argument is null
-
rainLevel
public float rainLevel()- Returns:
- the rain intensity used when this weather is fixed
-
thunderLevel
public float thunderLevel()- Returns:
- the thunder intensity used when this weather is fixed
-
decode
Decodes a weather state from a battle scene packet.- Parameters:
buffer- the packet buffer to read from- Returns:
- the decoded weather state
-
encode
public void encode(net.minecraft.network.FriendlyByteBuf buffer) Encodes this weather state for a battle scene packet.- Parameters:
buffer- the packet buffer to write to
-