public class ServerWorld extends World implements IForgeWorldServer
Modifier and Type | Field and Description |
---|---|
java.util.List<Teleporter> |
customTeleporters |
boolean |
disableLevelSaving |
protected java.util.Set<ChunkPos> |
doneChunks
Stores the recently processed (lighting) chunks
|
protected RaidManager |
raids |
addedTileEntityList, captureBlockSnapshots, capturedBlockSnapshots, chunkProvider, dimension, DIST_HASH_MAGIC, isRemote, loadedTileEntityList, prevRainingStrength, prevThunderingStrength, processingLoadedTiles, rainingStrength, rand, restoringBlockSnapshots, thunderingStrength, tickableTileEntities, tileEntitiesToBeRemoved, updateLCG, worldInfo
Constructor and Description |
---|
ServerWorld(MinecraftServer p_i50703_1_,
java.util.concurrent.Executor p_i50703_2_,
SaveHandler p_i50703_3_,
WorldInfo p_i50703_4_,
DimensionType p_i50703_5_,
IProfiler p_i50703_6_,
IChunkStatusListener p_i50703_7_) |
Modifier and Type | Method and Description |
---|---|
void |
addBlockEvent(BlockPos pos,
Block blockIn,
int eventID,
int eventParam) |
boolean |
addEntity(Entity entityIn) |
boolean |
addEntityIfNotDuplicate(Entity entityIn) |
void |
addLightningBolt(LightningBoltEntity entityIn) |
void |
addNewPlayer(ServerPlayerEntity player) |
void |
addRespawnedPlayer(ServerPlayerEntity player) |
protected BlockPos |
adjustPosToNearbyEntity(BlockPos pos) |
boolean |
canMineBlockBody(PlayerEntity player,
BlockPos pos) |
void |
checkSessionLock() |
void |
chunkCheck(Entity entityIn) |
it.unimi.dsi.fastutil.objects.Object2IntMap<EntityClassification> |
countEntities() |
protected void |
createBonusChest() |
Explosion |
createExplosion(Entity p_217401_1_,
DamageSource p_217401_2_,
double p_217401_3_,
double p_217401_5_,
double p_217401_7_,
float p_217401_9_,
boolean p_217401_10_,
Explosion.Mode p_217401_11_) |
void |
createSpawnPosition(WorldSettings settings) |
BlockPos |
findNearestStructure(java.lang.String name,
BlockPos pos,
int radius,
boolean p_211157_4_) |
Raid |
findRaid(BlockPos pos) |
boolean |
forceChunk(int chunkX,
int chunkZ,
boolean add) |
void |
func_217393_a(BlockPos p_217393_1_,
BlockState p_217393_2_,
BlockState p_217393_3_) |
void |
func_217399_a(MapData p_217399_1_) |
MapData |
func_217406_a(java.lang.String p_217406_1_) |
void |
func_217441_a(Chunk p_217441_1_,
int p_217441_2_) |
PointOfInterestManager |
func_217443_B() |
void |
func_217446_a(ServerPlayerEntity p_217446_1_) |
void |
func_217447_b(ServerPlayerEntity p_217447_1_) |
void |
func_217459_a(Entity p_217459_1_,
Entity p_217459_2_) |
void |
func_217460_e(Entity p_217460_1_) |
boolean |
func_217471_a(BlockPos p_217471_1_,
int p_217471_2_) |
boolean |
func_217483_b_(BlockPos p_217483_1_) |
int |
func_217486_a(SectionPos p_217486_1_) |
void |
func_217489_a(IReputationType p_217489_1_,
Entity p_217489_2_,
IReputationTracking p_217489_3_) |
boolean |
func_222887_a(SectionPos p_222887_1_) |
void |
func_225322_a(java.nio.file.Path p_225322_1_) |
ServerChunkProvider |
getChunkProvider() |
Teleporter |
getDefaultTeleporter() |
java.util.List<EnderDragonEntity> |
getDragons() |
java.util.stream.Stream<Entity> |
getEntities() |
java.util.List<Entity> |
getEntities(EntityType<?> p_217482_1_,
java.util.function.Predicate<? super Entity> p_217482_2_) |
Entity |
getEntityByID(int id) |
Entity |
getEntityByUuid(java.util.UUID p_217461_1_) |
it.unimi.dsi.fastutil.longs.LongSet |
getForcedChunks() |
int |
getNextMapId() |
ServerTickList<Block> |
getPendingBlockTicks() |
ServerTickList<Fluid> |
getPendingFluidTicks() |
java.util.List<ServerPlayerEntity> |
getPlayers() |
java.util.List<ServerPlayerEntity> |
getPlayers(java.util.function.Predicate<? super ServerPlayerEntity> p_217490_1_) |
RaidManager |
getRaids() |
ServerPlayerEntity |
getRandomPlayer() |
RecipeManager |
getRecipeManager() |
DimensionSavedDataManager |
getSavedData() |
SaveHandler |
getSaveHandler() |
ServerScoreboard |
getScoreboard() |
MinecraftServer |
getServer() |
BlockPos |
getSpawnCoordinate() |
TemplateManager |
getStructureTemplateManager() |
NetworkTagManager |
getTags() |
boolean |
hasRaid(BlockPos pos) |
protected void |
initCapabilities() |
boolean |
isBlockModifiable(PlayerEntity player,
BlockPos pos) |
boolean |
isInsideTick() |
boolean |
isSaveDisabled() |
void |
notifyBlockUpdate(BlockPos pos,
BlockState oldState,
BlockState newState,
int flags) |
void |
onChunkUnloading(Chunk chunkIn) |
void |
onEntityRemoved(Entity entityIn)
Deprecated.
|
void |
playBroadcastSound(int id,
BlockPos pos,
int data) |
void |
playEvent(PlayerEntity player,
int type,
BlockPos pos,
int data) |
void |
playMovingSound(PlayerEntity p_217384_1_,
Entity p_217384_2_,
SoundEvent p_217384_3_,
SoundCategory p_217384_4_,
float p_217384_5_,
float p_217384_6_) |
void |
playSound(PlayerEntity player,
double x,
double y,
double z,
SoundEvent soundIn,
SoundCategory category,
float volume,
float pitch) |
void |
removeEntity(Entity entityIn) |
void |
removeEntity(Entity entityIn,
boolean keepData) |
void |
removeEntityComplete(Entity entityIn,
boolean keepData) |
void |
removePlayer(ServerPlayerEntity player) |
void |
removePlayer(ServerPlayerEntity player,
boolean keepData) |
void |
resetUpdateEntityTick() |
void |
save(IProgressUpdate progress,
boolean flush,
boolean skipSave) |
protected void |
saveLevel() |
void |
sendBlockBreakProgress(int breakerId,
BlockPos pos,
int progress) |
void |
setEntityState(Entity entityIn,
byte state) |
void |
setGameTime(long worldTime) |
void |
setInitialSpawnLocation() |
void |
setSpawnPoint(BlockPos pos) |
<T extends IParticleData> |
spawnParticle(ServerPlayerEntity player,
T type,
boolean longDistance,
double posX,
double posY,
double posZ,
int particleCount,
double xOffset,
double yOffset,
double zOffset,
double speed) |
<T extends IParticleData> |
spawnParticle(T type,
double posX,
double posY,
double posZ,
int particleCount,
double xOffset,
double yOffset,
double zOffset,
double speed) |
boolean |
summonEntity(Entity p_217470_1_) |
void |
tick(java.util.function.BooleanSupplier hasTimeLeft) |
void |
updateAllPlayersSleepingFlag() |
void |
updateEntity(Entity entityIn) |
addOptionalParticle, addParticle, addParticle, addTileEntities, addTileEntity, advanceTime, calculateInitialSkylight, calculateInitialWeather, calculateInitialWeatherBody, checkBlockCollision, close, createExplosion, createExplosion, destroyBlock, extinguishFire, fillCrashReport, findBlockstateInArea, func_217383_a, func_217390_a, func_217391_K, func_217400_a, func_217404_b, func_225316_b, func_225319_b, getActualHeight, getBiome, getBiomeBody, getBlockState, getCelestialAngleRadians, getChunk, getChunk, getChunkAt, getChunkStatus, getCloudColorBody, getCloudColour, getDayTime, getDifficultyForLocation, getDimension, getEntitiesInAABBexcluding, getEntitiesWithinAABB, getEntitiesWithinAABB, getFluidState, getFogColor, getGameRules, getGameTime, getGroundAboveSeaLevel, getHeight, getHeight, getHorizon, getLastLightningBolt, getLightFor, getLightSubtracted, getMaxEntityRadius, getProfiler, getProviderName, getRainStrength, getRandom, getRedstonePower, getRedstonePowerFromNeighbors, getSeaLevel, getSeed, getSkyColor, getSkyColorBody, getSkylightSubtracted, getSpawnPoint, getStarBrightness, getStarBrightnessBody, getStrongPower, getSunBrightness, getSunBrightnessBody, getThunderStrength, getTileEntity, getWorld, getWorldBorder, getWorldInfo, getWorldType, hasBlockState, increaseMaxEntityRadius, isBlockinHighHumidity, isBlockPowered, isBlockPresent, isDaytime, isFlammableWithin, isMaterialInBB, isOutsideBuildHeight, isRaining, isRainingAt, isRemote, isSidePowered, isThundering, isValid, isYOutOfBounds, makeFireworks, markAndNotifyBlock, markChunkDirty, neighborChanged, notifyNeighbors, notifyNeighborsOfStateChange, notifyNeighborsOfStateExcept, playSound, playSound, removeBlock, removeTileEntity, sendPacketToServer, sendQuittingDisconnectingPacket, setAllowedSpawnTypes, setBlockState, setBlockState, setDayTime, setLastLightningBolt, setRainStrength, setThunderStrength, setTileEntity, updateComparatorOutputLevel
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCaps
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getWorldServer
getMaxEntityRadius, increaseMaxEntityRadius
getCapability, getCapability
checkNoEntityCollision, chunkExists, getCelestialAngle, getCurrentMoonPhaseFactor, getDifficulty, getEmptyCollisionShapes, getMoonPhase, playEvent
func_225317_b, func_225318_b, getClosestEntity, getClosestEntityWithinAABB, getClosestPlayer, getClosestPlayer, getClosestPlayer, getClosestPlayer, getClosestPlayer, getClosestPlayer, getClosestPlayer, getEntitiesWithinAABB, getEntitiesWithinAABBExcludingEntity, getPlayerByUuid, getTargettableEntitiesWithinAABB, getTargettablePlayersWithinAABB, isPlayerWithin
areCollisionShapesEmpty, areCollisionShapesEmpty, canBlockSeeSky, checkNoEntityCollision, containsAnyLiquid, func_217350_a, getBrightness, getChunk, getChunk, getCollisionShapes, getCollisionShapes, getLight, getNeighborAwareLightSubtracted, getStrongPower, hasWater, isAirBlock, isAreaLoaded, isAreaLoaded, isAreaLoaded, isBlockLoaded, isCollisionBoxesEmpty, isCollisionBoxesEmpty
getCombinedLight, isSkyLightMax
func_217296_a, func_217300_a, getHeight, getLightValue, getMaxLightLevel, rayTraceBlocks
getMaxHeight
public boolean disableLevelSaving
protected final RaidManager raids
protected java.util.Set<ChunkPos> doneChunks
public java.util.List<Teleporter> customTeleporters
public ServerWorld(MinecraftServer p_i50703_1_, java.util.concurrent.Executor p_i50703_2_, SaveHandler p_i50703_3_, WorldInfo p_i50703_4_, DimensionType p_i50703_5_, IProfiler p_i50703_6_, IChunkStatusListener p_i50703_7_)
public void tick(java.util.function.BooleanSupplier hasTimeLeft)
public void func_217441_a(Chunk p_217441_1_, int p_217441_2_)
public boolean isInsideTick()
public void updateAllPlayersSleepingFlag()
public ServerScoreboard getScoreboard()
getScoreboard
in class World
public void setInitialSpawnLocation()
setInitialSpawnLocation
in class World
public void resetUpdateEntityTick()
public void updateEntity(Entity entityIn)
public void chunkCheck(Entity entityIn)
public boolean isBlockModifiable(PlayerEntity player, BlockPos pos)
isBlockModifiable
in class World
public boolean canMineBlockBody(PlayerEntity player, BlockPos pos)
canMineBlockBody
in class World
public void createSpawnPosition(WorldSettings settings)
protected void createBonusChest()
@Nullable public BlockPos getSpawnCoordinate()
public void save(@Nullable IProgressUpdate progress, boolean flush, boolean skipSave) throws SessionLockException
SessionLockException
protected void saveLevel() throws SessionLockException
SessionLockException
public java.util.List<Entity> getEntities(@Nullable EntityType<?> p_217482_1_, java.util.function.Predicate<? super Entity> p_217482_2_)
public java.util.List<EnderDragonEntity> getDragons()
public java.util.List<ServerPlayerEntity> getPlayers(java.util.function.Predicate<? super ServerPlayerEntity> p_217490_1_)
@Nullable public ServerPlayerEntity getRandomPlayer()
public it.unimi.dsi.fastutil.objects.Object2IntMap<EntityClassification> countEntities()
public boolean addEntity(Entity entityIn)
addEntity
in interface IWorldWriter
public boolean summonEntity(Entity p_217470_1_)
public void func_217460_e(Entity p_217460_1_)
public void func_217446_a(ServerPlayerEntity p_217446_1_)
public void func_217447_b(ServerPlayerEntity p_217447_1_)
public void addNewPlayer(ServerPlayerEntity player)
public void addRespawnedPlayer(ServerPlayerEntity player)
public boolean addEntityIfNotDuplicate(Entity entityIn)
public void onChunkUnloading(Chunk chunkIn)
@Deprecated public void onEntityRemoved(Entity entityIn)
public void removeEntityComplete(Entity entityIn, boolean keepData)
public void removeEntity(Entity entityIn)
public void removeEntity(Entity entityIn, boolean keepData)
public void removePlayer(ServerPlayerEntity player)
public void removePlayer(ServerPlayerEntity player, boolean keepData)
public void addLightningBolt(LightningBoltEntity entityIn)
public void sendBlockBreakProgress(int breakerId, BlockPos pos, int progress)
sendBlockBreakProgress
in class World
public void playSound(@Nullable PlayerEntity player, double x, double y, double z, SoundEvent soundIn, SoundCategory category, float volume, float pitch)
public void playMovingSound(@Nullable PlayerEntity p_217384_1_, Entity p_217384_2_, SoundEvent p_217384_3_, SoundCategory p_217384_4_, float p_217384_5_, float p_217384_6_)
playMovingSound
in class World
public void playBroadcastSound(int id, BlockPos pos, int data)
playBroadcastSound
in class World
public void playEvent(@Nullable PlayerEntity player, int type, BlockPos pos, int data)
public void notifyBlockUpdate(BlockPos pos, BlockState oldState, BlockState newState, int flags)
notifyBlockUpdate
in class World
public void setEntityState(Entity entityIn, byte state)
setEntityState
in class World
public ServerChunkProvider getChunkProvider()
getChunkProvider
in interface IWorld
getChunkProvider
in class World
public Explosion createExplosion(@Nullable Entity p_217401_1_, DamageSource p_217401_2_, double p_217401_3_, double p_217401_5_, double p_217401_7_, float p_217401_9_, boolean p_217401_10_, Explosion.Mode p_217401_11_)
createExplosion
in class World
public void addBlockEvent(BlockPos pos, Block blockIn, int eventID, int eventParam)
addBlockEvent
in class World
public ServerTickList<Block> getPendingBlockTicks()
getPendingBlockTicks
in interface IWorld
public ServerTickList<Fluid> getPendingFluidTicks()
getPendingFluidTicks
in interface IWorld
@Nonnull public MinecraftServer getServer()
public Teleporter getDefaultTeleporter()
public TemplateManager getStructureTemplateManager()
public <T extends IParticleData> int spawnParticle(T type, double posX, double posY, double posZ, int particleCount, double xOffset, double yOffset, double zOffset, double speed)
public <T extends IParticleData> boolean spawnParticle(ServerPlayerEntity player, T type, boolean longDistance, double posX, double posY, double posZ, int particleCount, double xOffset, double yOffset, double zOffset, double speed)
@Nullable public Entity getEntityByID(int id)
getEntityByID
in class World
@Nullable public Entity getEntityByUuid(java.util.UUID p_217461_1_)
@Nullable public BlockPos findNearestStructure(java.lang.String name, BlockPos pos, int radius, boolean p_211157_4_)
findNearestStructure
in class World
public RecipeManager getRecipeManager()
getRecipeManager
in class World
public NetworkTagManager getTags()
public void setGameTime(long worldTime)
setGameTime
in class World
public boolean isSaveDisabled()
isSaveDisabled
in class World
public void checkSessionLock() throws SessionLockException
SessionLockException
public SaveHandler getSaveHandler()
public DimensionSavedDataManager getSavedData()
@Nullable public MapData func_217406_a(java.lang.String p_217406_1_)
func_217406_a
in class World
public void func_217399_a(MapData p_217399_1_)
func_217399_a
in class World
public int getNextMapId()
getNextMapId
in class World
public void setSpawnPoint(BlockPos pos)
setSpawnPoint
in class World
public it.unimi.dsi.fastutil.longs.LongSet getForcedChunks()
public boolean forceChunk(int chunkX, int chunkZ, boolean add)
public java.util.List<ServerPlayerEntity> getPlayers()
getPlayers
in interface IEntityReader
public void func_217393_a(BlockPos p_217393_1_, BlockState p_217393_2_, BlockState p_217393_3_)
func_217393_a
in class World
public PointOfInterestManager func_217443_B()
public boolean func_217483_b_(BlockPos p_217483_1_)
public boolean func_222887_a(SectionPos p_222887_1_)
public boolean func_217471_a(BlockPos p_217471_1_, int p_217471_2_)
public int func_217486_a(SectionPos p_217486_1_)
public RaidManager getRaids()
public boolean hasRaid(BlockPos pos)
public void func_217489_a(IReputationType p_217489_1_, Entity p_217489_2_, IReputationTracking p_217489_3_)
protected void initCapabilities()
public java.util.stream.Stream<Entity> getEntities()
public void func_225322_a(java.nio.file.Path p_225322_1_) throws java.io.IOException
java.io.IOException