public class WorldServer extends World
| Modifier and Type | Field and Description |
|---|---|
static WeightedRandomChestContent[] |
bonusChestContent |
java.util.List<Teleporter> |
customTeleporters |
protected java.util.Set<ChunkCoordIntPair> |
doneChunks
Stores the recently processed (lighting) chunks
|
boolean |
levelSaving
Whether or not level saving is enabled
|
ChunkProviderServer |
theChunkProviderServer |
activeChunkSet, captureBlockSnapshots, capturedBlockSnapshots, chunkProvider, difficultySetting, DIST_HASH_MAGIC, findingSpawnPoint, isRemote, lastLightningBolt, loadedEntityList, loadedTileEntityList, mapStorage, MAX_ENTITY_RADIUS, perWorldStorage, playerEntities, prevRainingStrength, prevThunderingStrength, provider, rainingStrength, rand, restoringBlockSnapshots, saveHandler, scheduledUpdatesAreImmediate, skylightSubtracted, spawnHostileMobs, spawnPeacefulMobs, theProfiler, thunderingStrength, unloadedEntityList, updateLCG, villageCollectionObj, villageSiegeObj, weatherEffects, worldAccesses, worldInfo, worldScoreboard| Constructor and Description |
|---|
WorldServer(MinecraftServer p_i45284_1_,
ISaveHandler p_i45284_2_,
java.lang.String p_i45284_3_,
int p_i45284_4_,
WorldSettings p_i45284_5_,
Profiler p_i45284_6_) |
| Modifier and Type | Method and Description |
|---|---|
void |
addBlockEvent(int p_147452_1_,
int p_147452_2_,
int p_147452_3_,
Block p_147452_4_,
int p_147452_5_,
int p_147452_6_)
Adds a block event with the given Args to the blockEventCache.
|
boolean |
addWeatherEffect(Entity p_72942_1_)
adds a lightning bolt to the list of lightning bolts in this world.
|
boolean |
areAllPlayersAsleep() |
boolean |
canMineBlock(EntityPlayer p_72962_1_,
int p_72962_2_,
int p_72962_3_,
int p_72962_4_)
Called when checking if a certain block can be mined or not.
|
boolean |
canMineBlockBody(EntityPlayer par1EntityPlayer,
int par2,
int par3,
int par4) |
protected void |
createBonusChest()
Creates the bonus chest in the world.
|
protected IChunkProvider |
createChunkProvider()
Creates the chunk provider for this world.
|
protected void |
createSpawnPosition(WorldSettings p_73052_1_)
creates a spawn position at random within 256 blocks of 0,0
|
void |
flush()
Syncs all changes to disk and wait for completion.
|
void |
func_147446_b(int p_147446_1_,
int p_147446_2_,
int p_147446_3_,
Block p_147446_4_,
int p_147446_5_,
int p_147446_6_) |
protected void |
func_147456_g() |
java.util.List |
func_147486_a(int p_147486_1_,
int p_147486_2_,
int p_147486_3_,
int p_147486_4_,
int p_147486_5_,
int p_147486_6_) |
void |
func_147487_a(java.lang.String p_147487_1_,
double p_147487_2_,
double p_147487_4_,
double p_147487_6_,
int p_147487_8_,
double p_147487_9_,
double p_147487_11_,
double p_147487_13_,
double p_147487_15_) |
protected int |
func_152379_p() |
MinecraftServer |
func_73046_m() |
java.io.File |
getChunkSaveLocation() |
Teleporter |
getDefaultTeleporter() |
Entity |
getEntityByID(int p_73045_1_)
Returns the Entity with the given ID, or null if it doesn't exist in this World.
|
EntityTracker |
getEntityTracker()
Gets the EntityTracker
|
ChunkCoordinates |
getEntrancePortalLocation()
Gets the hard-coded portal location to use when entering this dimension.
|
java.util.List |
getPendingBlockUpdates(Chunk p_72920_1_,
boolean p_72920_2_) |
PlayerManager |
getPlayerManager() |
protected void |
initialize(WorldSettings p_72963_1_) |
boolean |
isBlockTickScheduledThisTick(int p_147477_1_,
int p_147477_2_,
int p_147477_3_,
Block p_147477_4_)
Returns true if the given block will receive a scheduled tick in this tick.
|
Explosion |
newExplosion(Entity p_72885_1_,
double p_72885_2_,
double p_72885_4_,
double p_72885_6_,
float p_72885_8_,
boolean p_72885_9_,
boolean p_72885_10_)
returns a new explosion.
|
void |
onEntityAdded(Entity p_72923_1_) |
void |
onEntityRemoved(Entity p_72847_1_) |
void |
resetUpdateEntityTick()
Resets the updateEntityTick field to 0
|
void |
saveAllChunks(boolean p_73044_1_,
IProgressUpdate p_73044_2_)
Saves all chunks to disk while updating progress bar.
|
void |
saveChunkData()
saves chunk data - currently only called during execution of the Save All command
|
protected void |
saveLevel()
Saves the chunks to disk.
|
void |
scheduleBlockUpdate(int p_147464_1_,
int p_147464_2_,
int p_147464_3_,
Block p_147464_4_,
int p_147464_5_)
Schedules a tick to a block with a delay (Most commonly the tick rate)
|
void |
scheduleBlockUpdateWithPriority(int p_147454_1_,
int p_147454_2_,
int p_147454_3_,
Block p_147454_4_,
int p_147454_5_,
int p_147454_6_) |
void |
setEntityState(Entity p_72960_1_,
byte p_72960_2_)
sends a Packet 38 (Entity Status) to all tracked players of that entity
|
void |
setSpawnLocation()
Sets a new spawn location by finding an uncovered block at a random (x,z) location in the chunk.
|
BiomeGenBase.SpawnListEntry |
spawnRandomCreature(EnumCreatureType p_73057_1_,
int p_73057_2_,
int p_73057_3_,
int p_73057_4_)
only spawns creatures allowed by the chunkProvider
|
void |
tick()
Runs a single tick for the world
|
boolean |
tickUpdates(boolean p_72955_1_)
Runs through the list of updates to run and ticks them
|
void |
updateAllPlayersSleepingFlag()
Updates the flag that indicates whether or not all players in the world are sleeping.
|
void |
updateEntities()
Updates (and cleans up) entities and tile entities
|
void |
updateEntityWithOptionalForce(Entity p_72866_1_,
boolean p_72866_2_)
Will update the entity in the world if the chunk the entity is in is currently loaded or its forced to update.
|
protected void |
updateWeather()
Updates all weather states.
|
protected void |
wakeAllPlayers() |
addLoadedEntities, addTileEntity, addWorldAccess, addWorldInfoToCrashReport, blockExists, calculateInitialSkylight, calculateInitialWeatherBody, calculateSkylightSubtracted, canBlockFreeze, canBlockFreezeBody, canBlockSeeTheSky, canLightningStrikeAt, canPlaceEntityOnSide, canSnowAtBody, checkBlockCollision, checkChunksExist, checkNoEntityCollision, checkNoEntityCollision, checkSessionLock, chunkExists, countEntities, countEntities, createExplosion, destroyBlockInWorldPartially, doChunksNearChunkExist, doesBlockHaveSolidTopSurface, drawCloudsBody, extendedLevelsInChunkCache, extinguishFire, findClosestStructure, findNearestEntityWithinAABB, finishSetup, func_147447_a, func_147448_a, func_147450_X, func_147451_t, func_147453_f, func_147457_a, func_147461_a, func_147462_b, func_147467_a, func_147469_q, func_147470_e, func_147473_B, func_147478_e, func_147479_m, func_147480_a, func_152378_a, func_82738_a, getActualHeight, getBiomeGenForCoords, getBiomeGenForCoordsBody, getBlock, getBlockDensity, getBlockLightOpacity, getBlockLightValue_do, getBlockLightValue, getBlockMetadata, getBlockPowerInput, getCelestialAngle, getCelestialAngleRadians, getChunkFromBlockCoords, getChunkFromChunkCoords, getChunkHeightMapMinimum, getChunkProvider, getClosestPlayer, getClosestPlayerToEntity, getClosestVulnerablePlayer, getClosestVulnerablePlayerToEntity, getCloudColour, getCollidingBoundingBoxes, getCurrentDate, getCurrentMoonPhaseFactor, getCurrentMoonPhaseFactorBody, getDebugLoadedEntities, getEntitiesWithinAABB, getEntitiesWithinAABBExcludingEntity, getEntitiesWithinAABBExcludingEntity, getEntityPathToXYZ, getFogColor, getFullBlockLightValue, getGameRules, getHeight, getHeightValue, getHorizon, getIndirectPowerLevelTo, getIndirectPowerOutput, getLightBrightness, getLightBrightnessForSkyBlocks, getLoadedEntityList, getMoonPhase, getPathEntityToEntity, getPersistentChunks, getPlayerEntityByName, getPrecipitationHeight, getProviderName, getRainStrength, getSavedLightValue, getSaveHandler, getScoreboard, getSeed, getSkyBlockTypeBrightness, getSkyColor, getSkyColorBody, getSpawnPoint, getStarBrightness, getStarBrightnessBody, getStrongestIndirectPower, getSunBrightness, getSunBrightnessBody, getSunBrightnessFactor, getTileEntity, getTopBlock, getTopSolidOrLiquidBlock, getTotalWorldTime, getUniqueDataId, getWeightedThunderStrength, getWorldChunkManager, getWorldInfo, getWorldTime, handleMaterialAcceleration, isAABBInMaterial, isAirBlock, isAnyLiquid, isBlockFreezable, isBlockFreezableNaturally, isBlockHighHumidity, isBlockIndirectlyGettingPowered, isBlockNormalCubeDefault, isBlockProvidingPowerTo, isDaytime, isMaterialInBB, isRaining, isSideSolid, isSideSolid, isThundering, joinEntityInSurroundings, loadItemData, makeFireworks, markAndNotifyBlock, markBlockForUpdate, markBlockRangeForRenderUpdate, markBlocksDirtyVertical, markTileEntityChunkModified, notifyBlockChange, notifyBlockOfNeighborChange, notifyBlocksOfNeighborChange, notifyBlocksOfNeighborChange, playAuxSFX, playAuxSFXAtEntity, playBroadcastSound, playRecord, playSound, playSoundAtEntity, playSoundEffect, playSoundToNearExcept, rayTraceBlocks, rayTraceBlocks, removeEntity, removePlayerEntityDangerously, removeTileEntity, removeWorldAccess, selectEntitiesWithinAABB, sendQuittingDisconnectingPacket, setActivePlayerChunksAndCheckLight, setAllowedSpawnTypes, setBlock, setBlock, setBlockMetadataWithNotify, setBlockToAir, setItemData, setLightValue, setRainStrength, setRandomSeed, setSpawnLocation, setThunderStrength, setTileEntity, setWorldTime, spawnEntityInWorld, spawnParticle, unloadEntities, updateEntity, updateLightByType, updateWeatherBodypublic ChunkProviderServer theChunkProviderServer
public boolean levelSaving
public static final WeightedRandomChestContent[] bonusChestContent
protected java.util.Set<ChunkCoordIntPair> doneChunks
public java.util.List<Teleporter> customTeleporters
public WorldServer(MinecraftServer p_i45284_1_, ISaveHandler p_i45284_2_, java.lang.String p_i45284_3_, int p_i45284_4_, WorldSettings p_i45284_5_, Profiler p_i45284_6_)
public BiomeGenBase.SpawnListEntry spawnRandomCreature(EnumCreatureType p_73057_1_, int p_73057_2_, int p_73057_3_, int p_73057_4_)
public void updateAllPlayersSleepingFlag()
updateAllPlayersSleepingFlag in class Worldprotected void wakeAllPlayers()
public boolean areAllPlayersAsleep()
public void setSpawnLocation()
setSpawnLocation in class Worldprotected void func_147456_g()
func_147456_g in class Worldpublic boolean isBlockTickScheduledThisTick(int p_147477_1_,
int p_147477_2_,
int p_147477_3_,
Block p_147477_4_)
isBlockTickScheduledThisTick in class Worldpublic void scheduleBlockUpdate(int p_147464_1_,
int p_147464_2_,
int p_147464_3_,
Block p_147464_4_,
int p_147464_5_)
scheduleBlockUpdate in class Worldpublic void scheduleBlockUpdateWithPriority(int p_147454_1_,
int p_147454_2_,
int p_147454_3_,
Block p_147454_4_,
int p_147454_5_,
int p_147454_6_)
scheduleBlockUpdateWithPriority in class Worldpublic void func_147446_b(int p_147446_1_,
int p_147446_2_,
int p_147446_3_,
Block p_147446_4_,
int p_147446_5_,
int p_147446_6_)
func_147446_b in class Worldpublic void updateEntities()
updateEntities in class Worldpublic void resetUpdateEntityTick()
public boolean tickUpdates(boolean p_72955_1_)
tickUpdates in class Worldpublic java.util.List getPendingBlockUpdates(Chunk p_72920_1_, boolean p_72920_2_)
getPendingBlockUpdates in class Worldpublic void updateEntityWithOptionalForce(Entity p_72866_1_, boolean p_72866_2_)
updateEntityWithOptionalForce in class Worldprotected IChunkProvider createChunkProvider()
createChunkProvider in class Worldpublic java.util.List func_147486_a(int p_147486_1_,
int p_147486_2_,
int p_147486_3_,
int p_147486_4_,
int p_147486_5_,
int p_147486_6_)
public boolean canMineBlock(EntityPlayer p_72962_1_, int p_72962_2_, int p_72962_3_, int p_72962_4_)
canMineBlock in class Worldpublic boolean canMineBlockBody(EntityPlayer par1EntityPlayer, int par2, int par3, int par4)
canMineBlockBody in class Worldprotected void initialize(WorldSettings p_72963_1_)
initialize in class Worldprotected void createSpawnPosition(WorldSettings p_73052_1_)
protected void createBonusChest()
public ChunkCoordinates getEntrancePortalLocation()
public void saveAllChunks(boolean p_73044_1_,
IProgressUpdate p_73044_2_)
throws MinecraftException
MinecraftExceptionpublic void saveChunkData()
protected void saveLevel()
throws MinecraftException
MinecraftExceptionpublic void onEntityAdded(Entity p_72923_1_)
onEntityAdded in class Worldpublic void onEntityRemoved(Entity p_72847_1_)
onEntityRemoved in class Worldpublic Entity getEntityByID(int p_73045_1_)
getEntityByID in class Worldpublic boolean addWeatherEffect(Entity p_72942_1_)
addWeatherEffect in class Worldpublic void setEntityState(Entity p_72960_1_, byte p_72960_2_)
setEntityState in class Worldpublic Explosion newExplosion(Entity p_72885_1_, double p_72885_2_, double p_72885_4_, double p_72885_6_, float p_72885_8_, boolean p_72885_9_, boolean p_72885_10_)
newExplosion in class Worldpublic void addBlockEvent(int p_147452_1_,
int p_147452_2_,
int p_147452_3_,
Block p_147452_4_,
int p_147452_5_,
int p_147452_6_)
addBlockEvent in class Worldpublic void flush()
protected void updateWeather()
updateWeather in class Worldprotected int func_152379_p()
func_152379_p in class Worldpublic MinecraftServer func_73046_m()
public EntityTracker getEntityTracker()
public PlayerManager getPlayerManager()
public Teleporter getDefaultTeleporter()
public void func_147487_a(java.lang.String p_147487_1_,
double p_147487_2_,
double p_147487_4_,
double p_147487_6_,
int p_147487_8_,
double p_147487_9_,
double p_147487_11_,
double p_147487_13_,
double p_147487_15_)
public java.io.File getChunkSaveLocation()