Package net.minecraft.world.dimension
Record Class DimensionType
java.lang.Object
java.lang.Record
net.minecraft.world.dimension.DimensionType
- Record Components:
fixedTime-hasSkyLight-hasCeiling-ultrawarm-natural-coordinateScale-bedWorks-respawnAnchorWorks-minY-height-logicalHeight-infiniburn-effects-ambientLight-monsterSettings-
public record DimensionType(OptionalLong fixedTime, boolean hasSkyLight, boolean hasCeiling, boolean ultrawarm, boolean natural, double coordinateScale, boolean bedWorks, boolean respawnAnchorWorks, int minY, int height, int logicalHeight, TagKey<Block> infiniburn, Identifier effects, float ambientLight, DimensionType.MonsterSettings monsterSettings)
extends Record
- Mappings:
Namespace Name named net/minecraft/world/dimension/DimensionTypeintermediary net/minecraft/class_2874official efnnamed fixedTimeintermediary comp_641official mnamed hasSkyLightintermediary comp_642official nnamed hasCeilingintermediary comp_643official onamed ultrawarmintermediary comp_644official pnamed naturalintermediary comp_645official qnamed coordinateScaleintermediary comp_646official rnamed bedWorksintermediary comp_648official snamed respawnAnchorWorksintermediary comp_649official tnamed minYintermediary comp_651official unamed heightintermediary comp_652official vnamed logicalHeightintermediary comp_653official wnamed infiniburnintermediary comp_654official xnamed effectsintermediary comp_655official ynamed ambientLightintermediary comp_656official znamed monsterSettingsintermediary comp_847official A
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final floatThe field for theambientLightrecord component.private final booleanThe field for thebedWorksrecord component.static final com.mojang.serialization.Codec<DimensionType> private final doubleThe field for thecoordinateScalerecord component.private final IdentifierThe field for theeffectsrecord component.static final intstatic final intstatic final intstatic final intprivate final OptionalLongThe field for thefixedTimerecord component.private final booleanThe field for thehasCeilingrecord component.private final booleanThe field for thehasSkyLightrecord component.private final intThe field for theheightrecord component.The field for theinfiniburnrecord component.private final intThe field for thelogicalHeightrecord component.static final intstatic final intstatic final intprivate final intThe field for theminYrecord component.private final DimensionType.MonsterSettingsThe field for themonsterSettingsrecord component.static final float[]private final booleanThe field for thenaturalrecord component.static final PacketCodec<RegistryByteBuf, RegistryEntry<DimensionType>> static final com.mojang.serialization.Codec<RegistryEntry<DimensionType>> private final booleanThe field for therespawnAnchorWorksrecord component.static final intprivate final booleanThe field for theultrawarmrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionDimensionType(OptionalLong fixedTime, boolean hasSkylight, boolean hasCeiling, boolean ultrawarm, boolean natural, double coordinateScale, boolean bedWorks, boolean piglinSafe, int minY, int height, int logicalHeight, TagKey<Block> infiniburn, Identifier effects, float ambientLight, DimensionType.MonsterSettings monsterSettings) -
Method Summary
Modifier and TypeMethodDescriptionfloatReturns the value of theambientLightrecord component.booleanbedWorks()Returns the value of thebedWorksrecord component.doubleReturns the value of thecoordinateScalerecord component.effects()Returns the value of theeffectsrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefixedTimerecord component.static doublegetCoordinateScaleFactor(DimensionType fromDimension, DimensionType toDimension) intgetMoonPhase(long time) Gets the moon phase index of Minecraft's moon.static PathgetSaveDirectory(RegistryKey<World> worldRef, Path worldDirectory) floatgetSkyAngle(long time) booleanReturns the value of thehasCeilingrecord component.booleanfinal inthashCode()Returns a hash code value for this object.booleanhasRaids()booleanReturns the value of thehasSkyLightrecord component.intheight()Returns the value of theheightrecord component.Returns the value of theinfiniburnrecord component.intReturns the value of thelogicalHeightrecord component.intminY()Returns the value of theminYrecord component.Returns the value of themonsterSettingsrecord component.intbooleannatural()Returns the value of thenaturalrecord component.booleanbooleanReturns the value of therespawnAnchorWorksrecord component.final StringtoString()Returns a string representation of this record class.booleanReturns the value of theultrawarmrecord component.static com.mojang.serialization.DataResult<RegistryKey<World>> worldFromDimensionNbt(com.mojang.serialization.Dynamic<?> nbt) Deprecated.
-
Field Details
-
fixedTime
The field for thefixedTimerecord component. -
hasSkyLight
private final boolean hasSkyLightThe field for thehasSkyLightrecord component. -
hasCeiling
private final boolean hasCeilingThe field for thehasCeilingrecord component. -
ultrawarm
private final boolean ultrawarmThe field for theultrawarmrecord component. -
natural
private final boolean naturalThe field for thenaturalrecord component. -
coordinateScale
private final double coordinateScaleThe field for thecoordinateScalerecord component. -
bedWorks
private final boolean bedWorksThe field for thebedWorksrecord component. -
respawnAnchorWorks
private final boolean respawnAnchorWorksThe field for therespawnAnchorWorksrecord component. -
minY
private final int minYThe field for theminYrecord component. -
height
private final int heightThe field for theheightrecord component. -
logicalHeight
private final int logicalHeightThe field for thelogicalHeightrecord component. -
infiniburn
The field for theinfiniburnrecord component. -
effects
The field for theeffectsrecord component. -
ambientLight
private final float ambientLightThe field for theambientLightrecord component. -
monsterSettings
The field for themonsterSettingsrecord component. -
SIZE_BITS_Y
public static final int SIZE_BITS_Y- Mappings:
Namespace Name Mixin selector named SIZE_BITS_YLnet/minecraft/world/dimension/DimensionType;SIZE_BITS_Y:Iintermediary field_28133Lnet/minecraft/class_2874;field_28133:Iofficial aLefn;a:I
-
field_33411
public static final int field_33411- See Also:
- Mappings:
Namespace Name Mixin selector named field_33411Lnet/minecraft/world/dimension/DimensionType;field_33411:Iintermediary field_33411Lnet/minecraft/class_2874;field_33411:Iofficial bLefn;b:I
-
MAX_HEIGHT
public static final int MAX_HEIGHT- Mappings:
Namespace Name Mixin selector named MAX_HEIGHTLnet/minecraft/world/dimension/DimensionType;MAX_HEIGHT:Iintermediary field_28134Lnet/minecraft/class_2874;field_28134:Iofficial cLefn;c:I
-
MAX_COLUMN_HEIGHT
public static final int MAX_COLUMN_HEIGHT- Mappings:
Namespace Name Mixin selector named MAX_COLUMN_HEIGHTLnet/minecraft/world/dimension/DimensionType;MAX_COLUMN_HEIGHT:Iintermediary field_28135Lnet/minecraft/class_2874;field_28135:Iofficial dLefn;d:I
-
MIN_HEIGHT
public static final int MIN_HEIGHT- Mappings:
Namespace Name Mixin selector named MIN_HEIGHTLnet/minecraft/world/dimension/DimensionType;MIN_HEIGHT:Iintermediary field_28136Lnet/minecraft/class_2874;field_28136:Iofficial eLefn;e:I
-
field_35478
public static final int field_35478- Mappings:
Namespace Name Mixin selector named field_35478Lnet/minecraft/world/dimension/DimensionType;field_35478:Iintermediary field_35478Lnet/minecraft/class_2874;field_35478:Iofficial fLefn;f:I
-
field_35479
public static final int field_35479- Mappings:
Namespace Name Mixin selector named field_35479Lnet/minecraft/world/dimension/DimensionType;field_35479:Iintermediary field_35479Lnet/minecraft/class_2874;field_35479:Iofficial gLefn;g:I
-
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/world/dimension/DimensionType;CODEC:Lcom/mojang/serialization/Codec;intermediary field_24757Lnet/minecraft/class_2874;field_24757:Lcom/mojang/serialization/Codec;official hLefn;h:Lcom/mojang/serialization/Codec;
-
PACKET_CODEC
- Mappings:
Namespace Name Mixin selector named PACKET_CODECLnet/minecraft/world/dimension/DimensionType;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;intermediary field_51951Lnet/minecraft/class_2874;field_51951:Lnet/minecraft/class_9139;official iLefn;i:Lze;
-
field_31440
public static final int field_31440- See Also:
- Mappings:
Namespace Name Mixin selector named field_31440Lnet/minecraft/world/dimension/DimensionType;field_31440:Iintermediary field_31440Lnet/minecraft/class_2874;field_31440:Iofficial jLefn;j:I
-
MOON_SIZES
public static final float[] MOON_SIZES- Mappings:
Namespace Name Mixin selector named MOON_SIZESLnet/minecraft/world/dimension/DimensionType;MOON_SIZES:[Fintermediary field_24752Lnet/minecraft/class_2874;field_24752:[Fofficial kLefn;k:[F
-
REGISTRY_CODEC
- Mappings:
Namespace Name Mixin selector named REGISTRY_CODECLnet/minecraft/world/dimension/DimensionType;REGISTRY_CODEC:Lcom/mojang/serialization/Codec;intermediary field_24756Lnet/minecraft/class_2874;field_24756:Lcom/mojang/serialization/Codec;official lLefn;l:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
DimensionType
public DimensionType(OptionalLong fixedTime, boolean hasSkylight, boolean hasCeiling, boolean ultrawarm, boolean natural, double coordinateScale, boolean bedWorks, boolean piglinSafe, int minY, int height, int logicalHeight, TagKey<Block> infiniburn, Identifier effects, float ambientLight, DimensionType.MonsterSettings monsterSettings) - Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/world/dimension/DimensionType;<init>(Ljava/util/OptionalLong;ZZZZDZZIIILnet/minecraft/registry/tag/TagKey;Lnet/minecraft/util/Identifier;FLnet/minecraft/world/dimension/DimensionType$MonsterSettings;)Vintermediary <init>Lnet/minecraft/class_2874;<init>(Ljava/util/OptionalLong;ZZZZDZZIIILnet/minecraft/class_6862;Lnet/minecraft/class_2960;FLnet/minecraft/class_2874$class_7512;)Vofficial <init>Lefn;<init>(Ljava/util/OptionalLong;ZZZZDZZIIILayc;Lalr;FLefn$a;)V
-
-
Method Details
-
worldFromDimensionNbt
@Deprecated public static com.mojang.serialization.DataResult<RegistryKey<World>> worldFromDimensionNbt(com.mojang.serialization.Dynamic<?> nbt) Deprecated.- Mappings:
Namespace Name Mixin selector named worldFromDimensionNbtLnet/minecraft/world/dimension/DimensionType;worldFromDimensionNbt(Lcom/mojang/serialization/Dynamic;)Lcom/mojang/serialization/DataResult;intermediary method_28521Lnet/minecraft/class_2874;method_28521(Lcom/mojang/serialization/Dynamic;)Lcom/mojang/serialization/DataResult;official aLefn;a(Lcom/mojang/serialization/Dynamic;)Lcom/mojang/serialization/DataResult;
-
getCoordinateScaleFactor
public static double getCoordinateScaleFactor(DimensionType fromDimension, DimensionType toDimension) - Mappings:
Namespace Name Mixin selector named getCoordinateScaleFactorLnet/minecraft/world/dimension/DimensionType;getCoordinateScaleFactor(Lnet/minecraft/world/dimension/DimensionType;Lnet/minecraft/world/dimension/DimensionType;)Dintermediary method_31109Lnet/minecraft/class_2874;method_31109(Lnet/minecraft/class_2874;Lnet/minecraft/class_2874;)Dofficial aLefn;a(Lefn;Lefn;)D
-
getSaveDirectory
- Mappings:
Namespace Name Mixin selector named getSaveDirectoryLnet/minecraft/world/dimension/DimensionType;getSaveDirectory(Lnet/minecraft/registry/RegistryKey;Ljava/nio/file/Path;)Ljava/nio/file/Path;intermediary method_12488Lnet/minecraft/class_2874;method_12488(Lnet/minecraft/class_5321;Ljava/nio/file/Path;)Ljava/nio/file/Path;official aLefn;a(Lalq;Ljava/nio/file/Path;)Ljava/nio/file/Path;
-
hasFixedTime
public boolean hasFixedTime()- Mappings:
Namespace Name Mixin selector named hasFixedTimeLnet/minecraft/world/dimension/DimensionType;hasFixedTime()Zintermediary method_29960Lnet/minecraft/class_2874;method_29960()Zofficial aLefn;a()Z
-
getSkyAngle
public float getSkyAngle(long time) - Mappings:
Namespace Name Mixin selector named getSkyAngleLnet/minecraft/world/dimension/DimensionType;getSkyAngle(J)Fintermediary method_28528Lnet/minecraft/class_2874;method_28528(J)Fofficial aLefn;a(J)F
-
getMoonPhase
public int getMoonPhase(long time) Gets the moon phase index of Minecraft's moon.This is typically used to determine the size of the moon that should be rendered.
- Parameters:
time- the time to calculate the index from- Mappings:
Namespace Name Mixin selector named getMoonPhaseLnet/minecraft/world/dimension/DimensionType;getMoonPhase(J)Iintermediary method_28531Lnet/minecraft/class_2874;method_28531(J)Iofficial bLefn;b(J)I
-
piglinSafe
public boolean piglinSafe()- Mappings:
Namespace Name Mixin selector named piglinSafeLnet/minecraft/world/dimension/DimensionType;piglinSafe()Zintermediary method_44220Lnet/minecraft/class_2874;method_44220()Zofficial bLefn;b()Z
-
hasRaids
public boolean hasRaids()- Mappings:
Namespace Name Mixin selector named hasRaidsLnet/minecraft/world/dimension/DimensionType;hasRaids()Zintermediary method_44221Lnet/minecraft/class_2874;method_44221()Zofficial cLefn;c()Z
-
monsterSpawnLightTest
- Mappings:
Namespace Name Mixin selector named monsterSpawnLightTestLnet/minecraft/world/dimension/DimensionType;monsterSpawnLightTest()Lnet/minecraft/util/math/intprovider/IntProvider;intermediary method_44222Lnet/minecraft/class_2874;method_44222()Lnet/minecraft/class_6017;official dLefn;d()Lbuh;
-
monsterSpawnBlockLightLimit
public int monsterSpawnBlockLightLimit()- Mappings:
Namespace Name Mixin selector named monsterSpawnBlockLightLimitLnet/minecraft/world/dimension/DimensionType;monsterSpawnBlockLightLimit()Iintermediary method_44223Lnet/minecraft/class_2874;method_44223()Iofficial eLefn;e()I
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
fixedTime
Returns the value of thefixedTimerecord component.- Returns:
- the value of the
fixedTimerecord component
-
hasSkyLight
public boolean hasSkyLight()Returns the value of thehasSkyLightrecord component.- Returns:
- the value of the
hasSkyLightrecord component
-
hasCeiling
public boolean hasCeiling()Returns the value of thehasCeilingrecord component.- Returns:
- the value of the
hasCeilingrecord component
-
ultrawarm
public boolean ultrawarm()Returns the value of theultrawarmrecord component.- Returns:
- the value of the
ultrawarmrecord component
-
natural
public boolean natural()Returns the value of thenaturalrecord component.- Returns:
- the value of the
naturalrecord component
-
coordinateScale
public double coordinateScale()Returns the value of thecoordinateScalerecord component.- Returns:
- the value of the
coordinateScalerecord component
-
bedWorks
public boolean bedWorks()Returns the value of thebedWorksrecord component.- Returns:
- the value of the
bedWorksrecord component
-
respawnAnchorWorks
public boolean respawnAnchorWorks()Returns the value of therespawnAnchorWorksrecord component.- Returns:
- the value of the
respawnAnchorWorksrecord component
-
minY
public int minY()Returns the value of theminYrecord component.- Returns:
- the value of the
minYrecord component
-
height
public int height()Returns the value of theheightrecord component.- Returns:
- the value of the
heightrecord component
-
logicalHeight
public int logicalHeight()Returns the value of thelogicalHeightrecord component.- Returns:
- the value of the
logicalHeightrecord component
-
infiniburn
Returns the value of theinfiniburnrecord component.- Returns:
- the value of the
infiniburnrecord component
-
effects
Returns the value of theeffectsrecord component.- Returns:
- the value of the
effectsrecord component
-
ambientLight
public float ambientLight()Returns the value of theambientLightrecord component.- Returns:
- the value of the
ambientLightrecord component
-
monsterSettings
Returns the value of themonsterSettingsrecord component.- Returns:
- the value of the
monsterSettingsrecord component
-