Package net.minecraft.world
Enum Heightmap.Type
- All Implemented Interfaces:
Serializable
,Comparable<Heightmap.Type>
,java.lang.constant.Constable
,StringIdentifiable
- Enclosing class:
- Heightmap
public static enum Heightmap.Type extends Enum<Heightmap.Type> implements StringIdentifiable
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants Enum Constant Description MOTION_BLOCKING
MOTION_BLOCKING_NO_LEAVES
OCEAN_FLOOR
OCEAN_FLOOR_WG
WORLD_SURFACE
WORLD_SURFACE_WG
-
Field Summary
Fields Modifier and Type Field Description private Predicate<BlockState>
blockPredicate
private static Map<String,Heightmap.Type>
BY_NAME
static com.mojang.serialization.Codec<Heightmap.Type>
CODEC
private String
name
private Heightmap.Purpose
purpose
-
Constructor Summary
Constructors Modifier Constructor Description private
Type(String name, Heightmap.Purpose purpose, Predicate<BlockState> blockPredicate)
-
Method Summary
Modifier and Type Method Description String
asString()
static Heightmap.Type
byName(String name)
Predicate<BlockState>
getBlockPredicate()
String
getName()
boolean
isStoredServerSide()
boolean
shouldSendToClient()
static Heightmap.Type
valueOf(String name)
Returns the enum constant of this type with the specified name.static Heightmap.Type[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
WORLD_SURFACE_WG
-
WORLD_SURFACE
-
OCEAN_FLOOR_WG
-
OCEAN_FLOOR
-
MOTION_BLOCKING
-
MOTION_BLOCKING_NO_LEAVES
-
-
Field Details
-
CODEC
-
BY_NAME
-
name
-
purpose
-
blockPredicate
-
-
Constructor Details
-
Type
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException
- if the argument is null
-
getName
-
shouldSendToClient
public boolean shouldSendToClient() -
isStoredServerSide
@Environment(CLIENT) public boolean isStoredServerSide() -
byName
-
getBlockPredicate
-
asString
- Specified by:
asString
in interfaceStringIdentifiable
-