Package net.minecraft.world.storage
Class ServerWorldInfo
- java.lang.Object
-
- net.minecraft.world.storage.ServerWorldInfo
-
- All Implemented Interfaces:
IServerConfiguration
,IServerWorldInfo
,ISpawnWorldInfo
,IWorldInfo
public class ServerWorldInfo extends java.lang.Object implements IServerWorldInfo, IServerConfiguration
-
-
Field Summary
Fields Modifier and Type Field Description private int
clearWeatherTime
private CompoundNBT
customBossEvents
private long
dayTime
private boolean
difficultyLocked
private CompoundNBT
endDragonFightData
private com.mojang.datafixers.DataFixer
fixerUpper
private long
gameTime
private boolean
initialized
private java.util.Set<java.lang.String>
knownServerBrands
private CompoundNBT
loadedPlayerTag
private static org.apache.logging.log4j.Logger
LOGGER
private int
playerDataVersion
private boolean
raining
private int
rainTime
private TimerCallbackManager<MinecraftServer>
scheduledEvents
private WorldSettings
settings
private float
spawnAngle
private boolean
thundering
private int
thunderTime
private boolean
upgradedPlayerTag
private int
version
private java.util.UUID
wanderingTraderId
private int
wanderingTraderSpawnChance
private int
wanderingTraderSpawnDelay
private boolean
wasModded
private WorldBorder.Serializer
worldBorder
private DimensionGeneratorSettings
worldGenSettings
private com.mojang.serialization.Lifecycle
worldGenSettingsLifecycle
private int
xSpawn
private int
ySpawn
private int
zSpawn
-
Constructor Summary
Constructors Modifier Constructor Description private
ServerWorldInfo(com.mojang.datafixers.DataFixer p_i242043_1_, int p_i242043_2_, CompoundNBT p_i242043_3_, boolean p_i242043_4_, int p_i242043_5_, int p_i242043_6_, int p_i242043_7_, float p_i242043_8_, long p_i242043_9_, long p_i242043_11_, int p_i242043_13_, int p_i242043_14_, int p_i242043_15_, boolean p_i242043_16_, int p_i242043_17_, boolean p_i242043_18_, boolean p_i242043_19_, boolean p_i242043_20_, WorldBorder.Serializer p_i242043_21_, int p_i242043_22_, int p_i242043_23_, java.util.UUID p_i242043_24_, java.util.LinkedHashSet<java.lang.String> p_i242043_25_, TimerCallbackManager<MinecraftServer> p_i242043_26_, CompoundNBT p_i242043_27_, CompoundNBT p_i242043_28_, WorldSettings p_i242043_29_, DimensionGeneratorSettings p_i242043_30_, com.mojang.serialization.Lifecycle p_i242043_31_)
ServerWorldInfo(WorldSettings p_i232158_1_, DimensionGeneratorSettings p_i232158_2_, com.mojang.serialization.Lifecycle p_i232158_3_)
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.minecraft.world.storage.IServerConfiguration
getStorageVersionName
-
-
-
-
Field Detail
-
LOGGER
private static final org.apache.logging.log4j.Logger LOGGER
-
settings
private WorldSettings settings
-
worldGenSettings
private final DimensionGeneratorSettings worldGenSettings
-
worldGenSettingsLifecycle
private final com.mojang.serialization.Lifecycle worldGenSettingsLifecycle
-
xSpawn
private int xSpawn
-
ySpawn
private int ySpawn
-
zSpawn
private int zSpawn
-
spawnAngle
private float spawnAngle
-
gameTime
private long gameTime
-
dayTime
private long dayTime
-
fixerUpper
@Nullable private final com.mojang.datafixers.DataFixer fixerUpper
-
playerDataVersion
private final int playerDataVersion
-
upgradedPlayerTag
private boolean upgradedPlayerTag
-
loadedPlayerTag
@Nullable private CompoundNBT loadedPlayerTag
-
version
private final int version
-
clearWeatherTime
private int clearWeatherTime
-
raining
private boolean raining
-
rainTime
private int rainTime
-
thundering
private boolean thundering
-
thunderTime
private int thunderTime
-
initialized
private boolean initialized
-
difficultyLocked
private boolean difficultyLocked
-
worldBorder
private WorldBorder.Serializer worldBorder
-
endDragonFightData
private CompoundNBT endDragonFightData
-
customBossEvents
@Nullable private CompoundNBT customBossEvents
-
wanderingTraderSpawnDelay
private int wanderingTraderSpawnDelay
-
wanderingTraderSpawnChance
private int wanderingTraderSpawnChance
-
wanderingTraderId
@Nullable private java.util.UUID wanderingTraderId
-
knownServerBrands
private final java.util.Set<java.lang.String> knownServerBrands
-
wasModded
private boolean wasModded
-
scheduledEvents
private final TimerCallbackManager<MinecraftServer> scheduledEvents
-
-
Constructor Detail
-
ServerWorldInfo
private ServerWorldInfo(@Nullable com.mojang.datafixers.DataFixer p_i242043_1_, int p_i242043_2_, @Nullable CompoundNBT p_i242043_3_, boolean p_i242043_4_, int p_i242043_5_, int p_i242043_6_, int p_i242043_7_, float p_i242043_8_, long p_i242043_9_, long p_i242043_11_, int p_i242043_13_, int p_i242043_14_, int p_i242043_15_, boolean p_i242043_16_, int p_i242043_17_, boolean p_i242043_18_, boolean p_i242043_19_, boolean p_i242043_20_, WorldBorder.Serializer p_i242043_21_, int p_i242043_22_, int p_i242043_23_, @Nullable java.util.UUID p_i242043_24_, java.util.LinkedHashSet<java.lang.String> p_i242043_25_, TimerCallbackManager<MinecraftServer> p_i242043_26_, @Nullable CompoundNBT p_i242043_27_, CompoundNBT p_i242043_28_, WorldSettings p_i242043_29_, DimensionGeneratorSettings p_i242043_30_, com.mojang.serialization.Lifecycle p_i242043_31_)
-
ServerWorldInfo
public ServerWorldInfo(WorldSettings p_i232158_1_, DimensionGeneratorSettings p_i232158_2_, com.mojang.serialization.Lifecycle p_i232158_3_)
-
-
Method Detail
-
parse
public static ServerWorldInfo parse(com.mojang.serialization.Dynamic<INBT> p_237369_0_, com.mojang.datafixers.DataFixer p_237369_1_, int p_237369_2_, @Nullable CompoundNBT p_237369_3_, WorldSettings p_237369_4_, VersionData p_237369_5_, DimensionGeneratorSettings p_237369_6_, com.mojang.serialization.Lifecycle p_237369_7_)
-
createTag
public CompoundNBT createTag(DynamicRegistries p_230411_1_, @Nullable CompoundNBT p_230411_2_)
- Specified by:
createTag
in interfaceIServerConfiguration
-
setTagData
private void setTagData(DynamicRegistries p_237370_1_, CompoundNBT p_237370_2_, @Nullable CompoundNBT p_237370_3_)
-
getXSpawn
public int getXSpawn()
- Specified by:
getXSpawn
in interfaceIWorldInfo
-
getYSpawn
public int getYSpawn()
- Specified by:
getYSpawn
in interfaceIWorldInfo
-
getZSpawn
public int getZSpawn()
- Specified by:
getZSpawn
in interfaceIWorldInfo
-
getSpawnAngle
public float getSpawnAngle()
- Specified by:
getSpawnAngle
in interfaceIWorldInfo
-
getGameTime
public long getGameTime()
- Specified by:
getGameTime
in interfaceIWorldInfo
-
getDayTime
public long getDayTime()
- Specified by:
getDayTime
in interfaceIWorldInfo
-
updatePlayerTag
private void updatePlayerTag()
-
getLoadedPlayerTag
public CompoundNBT getLoadedPlayerTag()
- Specified by:
getLoadedPlayerTag
in interfaceIServerConfiguration
-
setXSpawn
public void setXSpawn(int p_76058_1_)
- Specified by:
setXSpawn
in interfaceISpawnWorldInfo
-
setYSpawn
public void setYSpawn(int p_76056_1_)
- Specified by:
setYSpawn
in interfaceISpawnWorldInfo
-
setZSpawn
public void setZSpawn(int p_76087_1_)
- Specified by:
setZSpawn
in interfaceISpawnWorldInfo
-
setSpawnAngle
public void setSpawnAngle(float p_241859_1_)
- Specified by:
setSpawnAngle
in interfaceISpawnWorldInfo
-
setGameTime
public void setGameTime(long p_82572_1_)
- Specified by:
setGameTime
in interfaceIServerWorldInfo
-
setDayTime
public void setDayTime(long p_76068_1_)
- Specified by:
setDayTime
in interfaceIServerWorldInfo
-
setSpawn
public void setSpawn(BlockPos p_176143_1_, float p_176143_2_)
- Specified by:
setSpawn
in interfaceISpawnWorldInfo
-
getLevelName
public java.lang.String getLevelName()
- Specified by:
getLevelName
in interfaceIServerConfiguration
- Specified by:
getLevelName
in interfaceIServerWorldInfo
-
getVersion
public int getVersion()
- Specified by:
getVersion
in interfaceIServerConfiguration
-
getClearWeatherTime
public int getClearWeatherTime()
- Specified by:
getClearWeatherTime
in interfaceIServerWorldInfo
-
setClearWeatherTime
public void setClearWeatherTime(int p_230391_1_)
- Specified by:
setClearWeatherTime
in interfaceIServerWorldInfo
-
isThundering
public boolean isThundering()
- Specified by:
isThundering
in interfaceIWorldInfo
-
setThundering
public void setThundering(boolean p_76069_1_)
- Specified by:
setThundering
in interfaceIServerWorldInfo
-
getThunderTime
public int getThunderTime()
- Specified by:
getThunderTime
in interfaceIServerWorldInfo
-
setThunderTime
public void setThunderTime(int p_76090_1_)
- Specified by:
setThunderTime
in interfaceIServerWorldInfo
-
isRaining
public boolean isRaining()
- Specified by:
isRaining
in interfaceIWorldInfo
-
setRaining
public void setRaining(boolean p_76084_1_)
- Specified by:
setRaining
in interfaceIWorldInfo
-
getRainTime
public int getRainTime()
- Specified by:
getRainTime
in interfaceIServerWorldInfo
-
setRainTime
public void setRainTime(int p_76080_1_)
- Specified by:
setRainTime
in interfaceIServerWorldInfo
-
getGameType
public GameType getGameType()
- Specified by:
getGameType
in interfaceIServerConfiguration
- Specified by:
getGameType
in interfaceIServerWorldInfo
-
setGameType
public void setGameType(GameType p_230392_1_)
- Specified by:
setGameType
in interfaceIServerConfiguration
- Specified by:
setGameType
in interfaceIServerWorldInfo
-
isHardcore
public boolean isHardcore()
- Specified by:
isHardcore
in interfaceIServerConfiguration
- Specified by:
isHardcore
in interfaceIWorldInfo
-
getAllowCommands
public boolean getAllowCommands()
- Specified by:
getAllowCommands
in interfaceIServerConfiguration
- Specified by:
getAllowCommands
in interfaceIServerWorldInfo
-
isInitialized
public boolean isInitialized()
- Specified by:
isInitialized
in interfaceIServerWorldInfo
-
setInitialized
public void setInitialized(boolean p_76091_1_)
- Specified by:
setInitialized
in interfaceIServerWorldInfo
-
getGameRules
public GameRules getGameRules()
- Specified by:
getGameRules
in interfaceIServerConfiguration
- Specified by:
getGameRules
in interfaceIWorldInfo
-
getWorldBorder
public WorldBorder.Serializer getWorldBorder()
- Specified by:
getWorldBorder
in interfaceIServerWorldInfo
-
setWorldBorder
public void setWorldBorder(WorldBorder.Serializer p_230393_1_)
- Specified by:
setWorldBorder
in interfaceIServerWorldInfo
-
getDifficulty
public Difficulty getDifficulty()
- Specified by:
getDifficulty
in interfaceIServerConfiguration
- Specified by:
getDifficulty
in interfaceIWorldInfo
-
setDifficulty
public void setDifficulty(Difficulty p_230409_1_)
- Specified by:
setDifficulty
in interfaceIServerConfiguration
-
isDifficultyLocked
public boolean isDifficultyLocked()
- Specified by:
isDifficultyLocked
in interfaceIServerConfiguration
- Specified by:
isDifficultyLocked
in interfaceIWorldInfo
-
setDifficultyLocked
public void setDifficultyLocked(boolean p_230415_1_)
- Specified by:
setDifficultyLocked
in interfaceIServerConfiguration
-
getScheduledEvents
public TimerCallbackManager<MinecraftServer> getScheduledEvents()
- Specified by:
getScheduledEvents
in interfaceIServerWorldInfo
-
fillCrashReportCategory
public void fillCrashReportCategory(CrashReportCategory p_85118_1_)
- Specified by:
fillCrashReportCategory
in interfaceIServerConfiguration
- Specified by:
fillCrashReportCategory
in interfaceIServerWorldInfo
- Specified by:
fillCrashReportCategory
in interfaceIWorldInfo
-
worldGenSettings
public DimensionGeneratorSettings worldGenSettings()
- Specified by:
worldGenSettings
in interfaceIServerConfiguration
-
worldGenSettingsLifecycle
public com.mojang.serialization.Lifecycle worldGenSettingsLifecycle()
- Specified by:
worldGenSettingsLifecycle
in interfaceIServerConfiguration
-
endDragonFightData
public CompoundNBT endDragonFightData()
- Specified by:
endDragonFightData
in interfaceIServerConfiguration
-
setEndDragonFightData
public void setEndDragonFightData(CompoundNBT p_230413_1_)
- Specified by:
setEndDragonFightData
in interfaceIServerConfiguration
-
getDataPackConfig
public DatapackCodec getDataPackConfig()
- Specified by:
getDataPackConfig
in interfaceIServerConfiguration
-
setDataPackConfig
public void setDataPackConfig(DatapackCodec p_230410_1_)
- Specified by:
setDataPackConfig
in interfaceIServerConfiguration
-
getCustomBossEvents
@Nullable public CompoundNBT getCustomBossEvents()
- Specified by:
getCustomBossEvents
in interfaceIServerConfiguration
-
setCustomBossEvents
public void setCustomBossEvents(@Nullable CompoundNBT p_230414_1_)
- Specified by:
setCustomBossEvents
in interfaceIServerConfiguration
-
getWanderingTraderSpawnDelay
public int getWanderingTraderSpawnDelay()
- Specified by:
getWanderingTraderSpawnDelay
in interfaceIServerWorldInfo
-
setWanderingTraderSpawnDelay
public void setWanderingTraderSpawnDelay(int p_230396_1_)
- Specified by:
setWanderingTraderSpawnDelay
in interfaceIServerWorldInfo
-
getWanderingTraderSpawnChance
public int getWanderingTraderSpawnChance()
- Specified by:
getWanderingTraderSpawnChance
in interfaceIServerWorldInfo
-
setWanderingTraderSpawnChance
public void setWanderingTraderSpawnChance(int p_230397_1_)
- Specified by:
setWanderingTraderSpawnChance
in interfaceIServerWorldInfo
-
setWanderingTraderId
public void setWanderingTraderId(java.util.UUID p_230394_1_)
- Specified by:
setWanderingTraderId
in interfaceIServerWorldInfo
-
setModdedInfo
public void setModdedInfo(java.lang.String p_230412_1_, boolean p_230412_2_)
- Specified by:
setModdedInfo
in interfaceIServerConfiguration
-
wasModded
public boolean wasModded()
- Specified by:
wasModded
in interfaceIServerConfiguration
-
getKnownServerBrands
public java.util.Set<java.lang.String> getKnownServerBrands()
- Specified by:
getKnownServerBrands
in interfaceIServerConfiguration
-
overworldData
public IServerWorldInfo overworldData()
- Specified by:
overworldData
in interfaceIServerConfiguration
-
getLevelSettings
public WorldSettings getLevelSettings()
- Specified by:
getLevelSettings
in interfaceIServerConfiguration
-
-