Interface World
- All Superinterfaces:
Audience, ForwardingAudience, Keyed, Pointered
-
Nested Class Summary
Nested classes/interfaces inherited from interface ForwardingAudience
ForwardingAudience.Single -
Method Summary
Modifier and TypeMethodDescriptionblockKeyAt(BlockPos pos) intblockLight(BlockPos pos) Returns this world's dimension type.Collection<? extends Entity> entities()entity(int entityId) Returns an immutable snapshot of the force-loaded chunks of this world.intgetBlockStateId(BlockPos pos) getChunkAsync(int chunkX, int chunkZ) default CompletableFuture<Chunk> getChunkAsync(ChunkPos pos) getChunkIfLoaded(int chunkX, int chunkZ) default ChunkgetChunkIfLoaded(ChunkPos pos) intheight()booleanisChunkForceLoaded(int chunkX, int chunkZ) Whether a chunk is force-loaded.default booleanWhether a chunk is force-loaded.default booleanisChunkLoaded(int chunkX, int chunkZ) intlightLevel(BlockPos pos) intminY()Returns the scheduler responsible for running tasks against positions in this world.booleansetBlockStateId(BlockPos pos, int stateId) booleansetChunkForceLoaded(int chunkX, int chunkZ, boolean forced) Sets the force-loaded state of a chunk.intunloadChunkAsync(int chunkX, int chunkZ) default CompletableFuture<Boolean> unloadChunkAsync(ChunkPos pos) Methods inherited from interface Audience
deleteMessage, openBook, openBook, removeResourcePacks, removeResourcePacks, removeResourcePacks, sendActionBar, sendMessage, sendMessage, sendPlayerListFooter, sendPlayerListHeader, sendPlayerListHeaderAndFooter, sendResourcePacks, sendResourcePacks, showTitle, stopSoundMethods inherited from interface ForwardingAudience
audiences, clearResourcePacks, clearTitle, closeDialog, deleteMessage, filterAudience, forEachAudience, hideBossBar, openBook, playSound, playSound, playSound, pointers, removeResourcePacks, removeResourcePacks, resetTitle, sendActionBar, sendMessage, sendMessage, sendMessage, sendPlayerListFooter, sendPlayerListHeader, sendPlayerListHeaderAndFooter, sendResourcePacks, sendTitlePart, showBossBar, showDialog, stopSoundMethods inherited from interface Pointered
get, getOrDefault, getOrDefaultFrom
-
Method Details
-
minY
int minY() -
height
int height() -
dimensionType
DimensionTypeDefinition dimensionType()Returns this world's dimension type.- Returns:
- this world's dimension type
- Since:
- 0.1.0
-
dayNightCycle
DayNightCycle dayNightCycle() -
scheduler
RegionizedScheduler scheduler()Returns the scheduler responsible for running tasks against positions in this world.- Returns:
- the scheduler responsible for running tasks against positions in this world
- Since:
- 0.1.0
-
getChunkAsync
-
getChunkAsync
-
getChunkIfLoaded
-
getChunkIfLoaded
-
isChunkForceLoaded
boolean isChunkForceLoaded(int chunkX, int chunkZ) Whether a chunk is force-loaded.- Parameters:
chunkX- the chunk X coordinatechunkZ- the chunk Z coordinate- Returns:
trueif the chunk is force-loaded- Since:
- 0.1.0
-
isChunkForceLoaded
Whether a chunk is force-loaded.- Parameters:
pos- the chunk position- Returns:
trueif the chunk is force-loaded- Since:
- 0.1.0
- See Also:
-
forceLoadedChunks
-
isChunkLoaded
default boolean isChunkLoaded(int chunkX, int chunkZ) -
blockKeyAt
-
getBlockStateId
-
setBlockStateId
-
blockLight
-
skyLight
-
lightLevel
-
entities
Collection<? extends Entity> entities() -
entity
-
entity
-
setChunkForceLoaded
boolean setChunkForceLoaded(int chunkX, int chunkZ, boolean forced) Sets the force-loaded state of a chunk.- Parameters:
chunkX- the chunk X coordinatechunkZ- the chunk Z coordinateforced- whether to force-load or unforce-load the chunk- Returns:
trueforces the chunk to remain loaded,falseremoves the loaded chunk- Since:
- 0.1.0
-
unloadChunkAsync
-
unloadChunkAsync
-