Package com.petrolpark.core.simulation
Class SimulatedServerLevel
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentHolder
net.minecraft.world.level.Level
net.minecraft.server.level.ServerLevel
com.petrolpark.core.simulation.SimulatedServerLevel
- All Implemented Interfaces:
AutoCloseable,net.minecraft.world.level.biome.BiomeManager.NoiseBiomeSource,net.minecraft.world.level.BlockAndTintGetter,net.minecraft.world.level.BlockGetter,net.minecraft.world.level.CollisionGetter,net.minecraft.world.level.CommonLevelAccessor,net.minecraft.world.level.EntityGetter,net.minecraft.world.level.LevelAccessor,net.minecraft.world.level.LevelHeightAccessor,net.minecraft.world.level.LevelReader,net.minecraft.world.level.LevelSimulatedReader,net.minecraft.world.level.LevelSimulatedRW,net.minecraft.world.level.LevelTimeAccess,net.minecraft.world.level.LevelWriter,net.minecraft.world.level.ServerLevelAccessor,net.minecraft.world.level.SignalGetter,net.minecraft.world.level.WorldGenLevel,net.neoforged.neoforge.attachment.IAttachmentHolder,net.neoforged.neoforge.common.extensions.IBlockAndTintGetterExtension,net.neoforged.neoforge.common.extensions.IBlockGetterExtension,net.neoforged.neoforge.common.extensions.ILevelExtension,net.neoforged.neoforge.common.extensions.ILevelReaderExtension
@Experimental
public class SimulatedServerLevel
extends net.minecraft.server.level.ServerLevel
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.Level
net.minecraft.world.level.Level.ExplosionInteractionNested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
net.neoforged.neoforge.attachment.AttachmentHolder.AsField -
Field Summary
Fields inherited from class net.minecraft.server.level.ServerLevel
END_SPAWN_POINT, noSave, raids, RAIN_DELAY, RAIN_DURATION, THUNDER_DURATIONFields inherited from class net.minecraft.world.level.Level
addend, blockEntityTickers, captureBlockSnapshots, capturedBlockSnapshots, END, isClientSide, levelData, LONG_PARTICLE_CLIP_RANGE, MAX_BRIGHTNESS, MAX_ENTITY_SPAWN_Y, MAX_LEVEL_SIZE, MIN_ENTITY_SPAWN_Y, neighborUpdater, NETHER, oRainLevel, oThunderLevel, OVERWORLD, rainLevel, random, randValue, RESOURCE_KEY_CODEC, restoringBlockSnapshots, SHORT_PARTICLE_CLIP_RANGE, thunderLevel, TICKS_PER_DAYFields inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
ATTACHMENTS_NBT_KEYFields inherited from interface net.neoforged.neoforge.common.extensions.ILevelExtension
TRANSLATION_PREFIXFields inherited from interface net.minecraft.world.level.SignalGetter
DIRECTIONS -
Constructor Summary
ConstructorsConstructorDescriptionSimulatedServerLevel(net.minecraft.server.MinecraftServer server, Executor dispatcher, net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess levelStorageAccess, net.minecraft.world.level.storage.ServerLevelData serverLevelData, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> dimension, net.minecraft.world.level.dimension.LevelStem levelStem, net.minecraft.server.level.progress.ChunkProgressListener progressListener, long biomeZoomSeed) -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.entity.EntitygetEntity(int id) net.minecraft.world.level.saveddata.maps.MapIdnet.minecraft.world.level.saveddata.maps.MapItemSavedDatagetMapData(net.minecraft.world.level.saveddata.maps.MapId mapId) List<net.minecraft.server.level.ServerPlayer> players()voidplaySound(net.minecraft.world.entity.player.Player player, double x, double y, double z, net.minecraft.sounds.SoundEvent soundEvent, net.minecraft.sounds.SoundSource soundSource, float volume, float pitch) voidplaySound(net.minecraft.world.entity.player.Player player, net.minecraft.world.entity.Entity entity, net.minecraft.sounds.SoundEvent soundEvent, net.minecraft.sounds.SoundSource soundSource, float volume, float pitch) voidsetMapData(net.minecraft.world.level.saveddata.maps.MapId mapId, net.minecraft.world.level.saveddata.maps.MapItemSavedData mapData) Methods inherited from class net.minecraft.server.level.ServerLevel
addDuringTeleport, addFreshEntity, addLegacyChunkEntities, addNewPlayer, addRespawnedPlayer, addWithUUID, addWorldGenChunkEntities, areEntitiesLoaded, blockEvent, blockUpdated, broadcastDamageEvent, broadcastEntityEvent, canSleepThroughNights, cleanCapabilityListenerReferences, clearBlockEvents, close, destroyBlockProgress, enabledFeatures, explode, fillReportDetails, findClosestBiome3d, findLightningTargetAround, findNearestMapStructure, gameEvent, gatherChunkSourceStats, getAllEntities, getBlockTicks, getChunkSource, getDataStorage, getDayTimeFraction, getDayTimePerTick, getDragonFight, getDragons, getEntities, getEntities, getEntities, getEntities, getEntity, getEntityOrPart, getFluidTicks, getForcedChunks, getLevel, getLogicalHeight, getPartEntities, getPathTypeCache, getPlayers, getPlayers, getPoiManager, getPortalForcer, getRaidAt, getRaids, getRandomPlayer, getRandomSequence, getRandomSequences, getRecipeManager, getScoreboard, getSeed, getServer, getShade, getStructureManager, getUncachedNoiseBiome, getWatchdogStats, globalLevelEvent, invalidateCapabilities, invalidateCapabilities, isCloseToVillage, isFlat, isHandlingTick, isNaturalSpawningAllowed, isNaturalSpawningAllowed, isPositionEntityTicking, isRaided, isVillage, isVillage, levelEvent, mayInteract, neighborChanged, neighborChanged, noSave, onBlockStateChange, onReputationEvent, onStructureStartsAvailable, playSeededSound, playSeededSound, potionBrewing, registerCapabilityListener, removePlayerImmediately, resetEmptyTime, resetWeatherCycle, save, saveDebugReport, sectionsToVillage, sendBlockUpdated, sendParticles, sendParticles, setChunkForced, setDayTime, setDayTimeFraction, setDayTimePerTick, setDefaultSpawnPos, setDragonFight, setWeatherParameters, shouldTickBlocksAt, startTickingChunk, structureManager, tick, tickChunk, tickCustomSpawners, tickNonPassenger, tickPrecipitation, tickRateManager, tickTime, toString, tryAddFreshEntityWithPassengers, unload, updateNeighborsAt, updateNeighborsAtExceptFromFacing, updateSleepingPlayerListMethods inherited from class net.minecraft.world.level.Level
addAlwaysVisibleParticle, addAlwaysVisibleParticle, addBlockEntityTicker, addDestroyBlockEffect, addFreshBlockEntities, addParticle, addParticle, advanceDaytime, blockEntityChanged, createFireworks, damageSources, destroyBlock, dimension, dimensionType, dimensionTypeRegistration, disconnect, explode, explode, explode, explode, explode, getBiomeManager, getBlockEntity, getBlockRandomPos, getBlockState, getChunk, getChunk, getChunkAt, getChunkForCollisions, getCurrentDifficultyAt, getDayTime, getEntities, getEntities, getEntities, getEntities, getFluidState, getGameRules, getGameTime, getHeight, getLevelData, getLightEngine, getMaxEntityRadius, getProfiler, getProfilerSupplier, getRainLevel, getRandom, getSeaLevel, getSharedSpawnAngle, getSharedSpawnPos, getSkyDarken, getSunAngle, getThunderLevel, getWorldBorder, guardEntityTick, increaseMaxEntityRadius, isClientSide, isDay, isDebug, isFluidAtPosition, isInSpawnableBounds, isInWorldBounds, isLoaded, isNight, isRaining, isRainingAt, isStateAtPosition, isThundering, loadedAndEntityCanStandOn, loadedAndEntityCanStandOnFace, markAndNotifyBlock, neighborShapeChanged, nextSubTickCount, playLocalSound, playLocalSound, playLocalSound, playSeededSound, playSound, playSound, playSound, playSound, prepareWeather, registryAccess, removeBlock, removeBlockEntity, sendPacketToServer, setBlock, setBlock, setBlockAndUpdate, setBlockEntity, setBlocksDirty, setRainLevel, setSkyFlashTime, setSpawnSettings, setThunderLevel, shouldTickBlocksAt, shouldTickDeath, tickBlockEntities, updateNeighbourForOutputSignal, updateSkyBrightnessMethods inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
deserializeAttachments, getData, getExistingData, hasAttachments, hasData, removeData, serializeAttachments, setDataMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.world.level.BlockAndTintGetter
canSeeSky, getBrightness, getLightEngine, getRawBrightnessMethods inherited from interface net.minecraft.world.level.BlockGetter
clip, clipWithInteractionOverride, getBlockEntity, getBlockFloorHeight, getBlockFloorHeight, getBlockState, getBlockStates, getFluidState, getLightEmission, getMaxLightLevel, isBlockInLineMethods inherited from interface net.minecraft.world.level.CollisionGetter
collidesWithSuffocatingBlock, findFreePosition, findSupportingBlock, getBlockCollisions, getCollisions, getEntityCollisions, getWorldBorder, isUnobstructed, isUnobstructed, isUnobstructed, noBlockCollision, noCollision, noCollision, noCollisionMethods inherited from interface net.minecraft.world.level.CommonLevelAccessor
getBlockEntity, getEntityCollisions, getHeightmapPos, isUnobstructedMethods inherited from interface net.minecraft.world.level.EntityGetter
getEntities, getEntities, getEntities, getEntitiesOfClass, getEntitiesOfClass, getNearbyEntities, getNearbyPlayers, getNearestEntity, getNearestEntity, getNearestPlayer, getNearestPlayer, getNearestPlayer, getNearestPlayer, getNearestPlayer, getNearestPlayer, getPlayerByUUID, hasNearbyAlivePlayerMethods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHolder
getData, getExistingData, hasData, removeData, setDataMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockAndTintGetterExtension
getShadeMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockGetterExtension
getAuxLightManager, getAuxLightManager, getModelDataMethods inherited from interface net.neoforged.neoforge.common.extensions.ILevelExtension
getCapability, getCapability, getCapability, getCapability, getDescription, getDescriptionKey, getModelDataManagerMethods inherited from interface net.neoforged.neoforge.common.extensions.ILevelReaderExtension
holder, holderOrThrow, isAreaLoadedMethods inherited from interface net.minecraft.world.level.LevelAccessor
addParticle, dayTime, gameEvent, gameEvent, gameEvent, gameEvent, getCurrentDifficultyAt, getDifficulty, getLevelData, getRandom, hasChunk, levelEvent, neighborShapeChanged, nextSubTickCount, playSound, playSound, scheduleTick, scheduleTick, scheduleTick, scheduleTickMethods inherited from interface net.minecraft.world.level.LevelHeightAccessor
getMaxBuildHeight, getMaxSection, getMinSection, getSectionIndex, getSectionIndexFromSectionY, getSectionsCount, getSectionYFromSectionIndex, isOutsideBuildHeight, isOutsideBuildHeightMethods inherited from interface net.minecraft.world.level.LevelReader
canSeeSkyFromBelowWater, containsAnyLiquid, dimensionType, getBiome, getBiomeManager, getBlockStatesIfLoaded, getBlockTint, getChunk, getChunk, getChunk, getChunk, getChunkForCollisions, getHeight, getHeight, getLightLevelDependentMagicValue, getMaxLocalRawBrightness, getMaxLocalRawBrightness, getMinBuildHeight, getNoiseBiome, getPathfindingCostFromLightLevels, getSeaLevel, getSkyDarken, hasChunkAt, hasChunkAt, hasChunksAt, hasChunksAt, hasChunksAt, holderLookup, isClientSide, isEmptyBlock, isWaterAt, registryAccessMethods inherited from interface net.minecraft.world.level.LevelSimulatedReader
isFluidAtPosition, isStateAtPositionMethods inherited from interface net.minecraft.world.level.LevelTimeAccess
getMoonBrightness, getMoonPhase, getTimeOfDayMethods inherited from interface net.minecraft.world.level.LevelWriter
destroyBlock, destroyBlock, destroyBlock, removeBlock, setBlock, setBlockMethods inherited from interface net.minecraft.world.level.ServerLevelAccessor
addFreshEntityWithPassengersMethods inherited from interface net.minecraft.world.level.SignalGetter
getBestNeighborSignal, getControlInputSignal, getDirectSignal, getDirectSignalTo, getSignal, hasNeighborSignal, hasSignalMethods inherited from interface net.minecraft.world.level.WorldGenLevel
ensureCanWrite, setCurrentlyGenerating
-
Constructor Details
-
SimulatedServerLevel
public SimulatedServerLevel(net.minecraft.server.MinecraftServer server, Executor dispatcher, net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess levelStorageAccess, net.minecraft.world.level.storage.ServerLevelData serverLevelData, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> dimension, net.minecraft.world.level.dimension.LevelStem levelStem, net.minecraft.server.level.progress.ChunkProgressListener progressListener, long biomeZoomSeed)
-
-
Method Details
-
players
- Specified by:
playersin interfacenet.minecraft.world.level.EntityGetter- Overrides:
playersin classnet.minecraft.server.level.ServerLevel
-
playSound
public void playSound(@Nullable net.minecraft.world.entity.player.Player player, double x, double y, double z, @Nonnull net.minecraft.sounds.SoundEvent soundEvent, @Nonnull net.minecraft.sounds.SoundSource soundSource, float volume, float pitch) - Overrides:
playSoundin classnet.minecraft.world.level.Level
-
playSound
public void playSound(@Nullable net.minecraft.world.entity.player.Player player, @Nonnull net.minecraft.world.entity.Entity entity, @Nonnull net.minecraft.sounds.SoundEvent soundEvent, @Nonnull net.minecraft.sounds.SoundSource soundSource, float volume, float pitch) - Overrides:
playSoundin classnet.minecraft.world.level.Level
-
getEntity
public net.minecraft.world.entity.Entity getEntity(int id) - Overrides:
getEntityin classnet.minecraft.server.level.ServerLevel
-
getMapData
@Nullable public net.minecraft.world.level.saveddata.maps.MapItemSavedData getMapData(@Nonnull net.minecraft.world.level.saveddata.maps.MapId mapId) - Overrides:
getMapDatain classnet.minecraft.server.level.ServerLevel
-
setMapData
public void setMapData(@Nonnull net.minecraft.world.level.saveddata.maps.MapId mapId, @Nonnull net.minecraft.world.level.saveddata.maps.MapItemSavedData mapData) - Overrides:
setMapDatain classnet.minecraft.server.level.ServerLevel
-
getFreeMapId
public net.minecraft.world.level.saveddata.maps.MapId getFreeMapId()- Overrides:
getFreeMapIdin classnet.minecraft.server.level.ServerLevel
-