Class SandboxLevel

java.lang.Object
net.minecraft.world.level.Level
com.thecsdev.commonmc.world.sandbox.SandboxLevel
All Implemented Interfaces:
AutoCloseable, net.minecraft.world.level.biome.BiomeManager.NoiseBiomeSource, net.minecraft.world.level.BlockAndLightGetter, 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.LevelWriter, net.minecraft.world.level.ScheduledTickAccess, net.minecraft.world.level.SignalGetter

@Internal @Virtual public class SandboxLevel extends net.minecraft.world.level.Level
Barebones minimal Level implementation.
  • Nested Class Summary

    Nested classes/interfaces inherited from class net.minecraft.world.level.Level

    net.minecraft.world.level.Level.ExplosionInteraction

    Nested classes/interfaces inherited from interface net.minecraft.world.level.BlockGetter

    net.minecraft.world.level.BlockGetter.BlockStepVisitor
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected @NotNull net.minecraft.world.level.chunk.ChunkSource
     
    protected @NotNull net.minecraft.world.clock.ClockManager
     
    protected @NotNull List<net.minecraft.world.entity.boss.enderdragon.EnderDragonPart>
     
    protected @NotNull net.minecraft.world.level.entity.TransientEntitySectionManager<net.minecraft.world.entity.Entity>
     
    protected @NotNull net.minecraft.world.level.block.entity.FuelValues
     
    static final SandboxLevel
    Primary SandboxLevel instance that is used ApiStatus.Internally.
    protected @NotNull List<net.minecraft.world.entity.player.Player>
     
    protected @NotNull net.minecraft.world.item.alchemy.PotionBrewing
     
    protected @NotNull net.minecraft.world.item.crafting.RecipeAccess
     
    protected @NotNull net.minecraft.world.scores.Scoreboard
     
    protected @NotNull net.minecraft.world.TickRateManager
     
    protected @NotNull net.minecraft.world.level.border.WorldBorder
     

    Fields inherited from class net.minecraft.world.level.Level

    ACROSS_THE_WHOLE_WORLD, addend, blockEntityTickers, END, 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, SHORT_PARTICLE_CLIP_RANGE, thunderLevel

    Fields inherited from interface net.minecraft.world.level.SignalGetter

    DIRECTIONS
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    SandboxLevel(net.minecraft.world.level.storage.WritableLevelData properties, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> registryRef, net.minecraft.core.RegistryAccess registryManager, net.minecraft.core.Holder<net.minecraft.world.level.dimension.DimensionType> dimensionEntry, boolean isClient, boolean debugWorld, long seed, int maxChainedNeighborUpdates)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.world.clock.ClockManager
     
    void
    destroyBlockProgress(int entityId, net.minecraft.core.BlockPos position, int progress)
     
    Collection<net.minecraft.world.entity.boss.enderdragon.EnderDragonPart>
     
    net.minecraft.world.flag.FeatureFlagSet
     
    net.minecraft.world.attribute.EnvironmentAttributeSystem
     
    void
    explode(@Nullable net.minecraft.world.entity.Entity entity, @Nullable net.minecraft.world.damagesource.DamageSource damageSource, @Nullable net.minecraft.world.level.ExplosionDamageCalculator behavior, double x, double y, double z, float power, boolean createFire, net.minecraft.world.level.Level.ExplosionInteraction explosionSourceType, net.minecraft.core.particles.ParticleOptions smallParticle, net.minecraft.core.particles.ParticleOptions largeParticle, net.minecraft.util.random.WeightedList<net.minecraft.core.particles.ExplosionParticleInfo> blockParticles, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> soundEvent)
     
    net.minecraft.world.level.block.entity.FuelValues
     
    void
    gameEvent(net.minecraft.core.Holder<net.minecraft.world.level.gameevent.GameEvent> event, net.minecraft.world.phys.Vec3 emitterPosition, net.minecraft.world.level.gameevent.GameEvent.Context emitter)
     
     
    net.minecraft.world.ticks.LevelTickAccess<net.minecraft.world.level.block.Block>
     
    net.minecraft.world.level.chunk.ChunkSource
     
    protected net.minecraft.world.level.entity.LevelEntityGetter<net.minecraft.world.entity.Entity>
     
    @Nullable net.minecraft.world.entity.Entity
    getEntity(int entityId)
     
    net.minecraft.world.ticks.LevelTickAccess<net.minecraft.world.level.material.Fluid>
     
    @Nullable net.minecraft.world.level.saveddata.maps.MapItemSavedData
    getMapData(net.minecraft.world.level.saveddata.maps.MapId mapId)
     
    net.minecraft.world.level.storage.LevelData.RespawnData
     
    net.minecraft.world.scores.Scoreboard
     
    int
     
    net.minecraft.core.Holder<net.minecraft.world.level.biome.Biome>
    getUncachedNoiseBiome(int biomeX, int biomeY, int biomeZ)
     
    net.minecraft.world.level.border.WorldBorder
     
    void
    levelEvent(@Nullable net.minecraft.world.entity.Entity source, int eventId, net.minecraft.core.BlockPos position, int data)
     
    List<? extends net.minecraft.world.entity.player.Player>
     
    void
    playSeededSound(@Nullable net.minecraft.world.entity.Entity source, double x, double y, double z, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> sound, net.minecraft.sounds.SoundSource category, float volume, float pitch, long speed)
     
    void
    playSeededSound(@Nullable net.minecraft.world.entity.Entity source, net.minecraft.world.entity.Entity entity, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> sound, net.minecraft.sounds.SoundSource category, float volume, float pitch, long speed)
     
    net.minecraft.world.item.alchemy.PotionBrewing
     
    net.minecraft.world.item.crafting.RecipeAccess
     
    void
    sendBlockUpdated(net.minecraft.core.BlockPos position, net.minecraft.world.level.block.state.BlockState oldState, net.minecraft.world.level.block.state.BlockState newState, int flags)
     
    void
    setRespawnData(net.minecraft.world.level.storage.LevelData.RespawnData spawnPoint)
     
    net.minecraft.world.TickRateManager
     

    Methods inherited from class net.minecraft.world.level.Level

    addAlwaysVisibleParticle, addAlwaysVisibleParticle, addBlockEntityTicker, addDestroyBlockEffect, addParticle, addParticle, blockEntityChanged, blockEvent, broadcastDamageEvent, broadcastEntityEvent, canHaveWeather, close, createFireworks, damageSources, destroyBlock, dimension, dimensionType, dimensionTypeRegistration, explode, explode, explode, explode, fillReportDetails, getBiomeManager, getBlockEntity, getBlockRandomPos, getBlockState, getChunk, getChunk, getChunkAt, getChunkForCollisions, getClientLeafTintColor, getDefaultClockTime, getEntities, getEntities, getEntities, getEntities, getEntity, getEntityInAnyDimension, getFluidState, getHeight, getLevelData, getLightEngine, getNextEntityId, getOverworldClockTime, getPlayerInAnyDimension, getPushableEntities, getRainLevel, getRandom, getServer, getSkyDarken, getThunderLevel, getWorldBorderAdjustedRespawnData, globalLevelEvent, guardEntityTick, hasEntities, isBrightOutside, isClientSide, isDarkOutside, isDebug, isFluidAtPosition, isInSpawnableBounds, isInValidBounds, isInWorldBounds, isLoaded, isRaining, isRainingAt, isStateAtPosition, isThundering, loadedAndEntityCanStandOn, loadedAndEntityCanStandOnFace, mayInteract, neighborChanged, neighborChanged, neighborShapeChanged, nextSubTickCount, noSave, onBlockEntityAdded, palettedContainerFactory, playLocalSound, playLocalSound, playLocalSound, playPlayerSound, playSeededSound, playSound, playSound, playSound, playSound, playSound, precipitationAt, registryAccess, removeBlock, removeBlockEntity, sendPacketToServer, setBlock, setBlock, setBlockAndUpdate, setBlockEntity, setBlocksDirty, setRainLevel, setSkyFlashTime, setSpawnSettings, setThunderLevel, shouldTickBlocksAt, shouldTickBlocksAt, shouldTickDeath, tickBlockEntities, updateNeighborsAt, updateNeighborsAtExceptFromFacing, updateNeighbourForOutputSignal, updatePOIOnBlockStateChange, updateSkyBrightness

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface net.minecraft.world.level.BlockAndLightGetter

    canSeeSky, getBrightness, getRawBrightness

    Methods inherited from interface net.minecraft.world.level.BlockGetter

    clip, clipWithInteractionOverride, getBlockFloorHeight, getBlockFloorHeight, getBlockStates, getLightEmission, isBlockInLine

    Methods inherited from interface net.minecraft.world.level.CollisionGetter

    clipIncludingBorder, collidesWithSuffocatingBlock, findFreePosition, findSupportingBlock, getBlockAndLiquidCollisions, getBlockCollisions, getBlockCollisionsFromContext, getCollisions, getPreMoveCollisions, isUnobstructed, isUnobstructed, noBlockCollision, noBlockCollision, noBorderCollision, noCollision, noCollision, noCollision, noCollision, noEntityCollision

    Methods inherited from interface net.minecraft.world.level.CommonLevelAccessor

    getBlockEntity, getEntityCollisions, getHeightmapPos, isUnobstructed

    Methods inherited from interface net.minecraft.world.level.EntityGetter

    getEntities, getEntitiesOfClass, getEntitiesOfClass, getNearestPlayer, getNearestPlayer, getNearestPlayer, getPlayerByUUID, hasNearbyAlivePlayer

    Methods inherited from interface net.minecraft.world.level.LevelAccessor

    createTick, createTick, gameEvent, gameEvent, gameEvent, gameEvent, getDifficulty, getGameTime, hasChunk, levelEvent, playSound, updateNeighborsAt

    Methods inherited from interface net.minecraft.world.level.LevelHeightAccessor

    getMaxSectionY, getMaxY, getMinSectionY, getSectionIndex, getSectionIndexFromSectionY, getSectionsCount, getSectionYFromSectionIndex, isInsideBuildHeight, isInsideBuildHeight, isOutsideBuildHeight, isOutsideBuildHeight

    Methods inherited from interface net.minecraft.world.level.LevelReader

    canSeeSkyFromBelowWater, containsAnyLiquid, getBiome, getBlockStatesIfLoaded, getChunk, getChunk, getEffectiveSkyBrightness, getHeight, getHeight, getLightLevelDependentMagicValue, getMaxLocalRawBrightness, getMaxLocalRawBrightness, getMinY, getNoiseBiome, getPathfindingCostFromLightLevels, hasChunkAt, hasChunkAt, hasChunksAt, hasChunksAt, hasChunksAt, holderLookup, isEmptyBlock, isWaterAt

    Methods inherited from interface net.minecraft.world.level.LevelWriter

    addFreshEntity, destroyBlock, destroyBlock

    Methods inherited from interface net.minecraft.world.level.ScheduledTickAccess

    scheduleTick, scheduleTick, scheduleTick, scheduleTick

    Methods inherited from interface net.minecraft.world.level.SignalGetter

    getBestNeighborSignal, getBestOwnOrNeighbourSignal, getControlInputSignal, getDirectSignal, getDirectSignalTo, getSignal, hasNeighborSignal, hasSignal
  • Field Details

    • entityManager

      @NotNull protected @NotNull net.minecraft.world.level.entity.TransientEntitySectionManager<net.minecraft.world.entity.Entity> entityManager
    • clockManager

      @NotNull protected @NotNull net.minecraft.world.clock.ClockManager clockManager
    • dragonParts

      @NotNull protected @NotNull List<net.minecraft.world.entity.boss.enderdragon.EnderDragonPart> dragonParts
    • tickRateManager

      @NotNull protected @NotNull net.minecraft.world.TickRateManager tickRateManager
    • scoreboard

      @NotNull protected @NotNull net.minecraft.world.scores.Scoreboard scoreboard
    • recipeAccess

      @NotNull protected @NotNull net.minecraft.world.item.crafting.RecipeAccess recipeAccess
    • potionBrewing

      @NotNull protected @NotNull net.minecraft.world.item.alchemy.PotionBrewing potionBrewing
    • fuelValues

      @NotNull protected @NotNull net.minecraft.world.level.block.entity.FuelValues fuelValues
    • chunkSource

      @NotNull protected @NotNull net.minecraft.world.level.chunk.ChunkSource chunkSource
    • players

      @NotNull protected @NotNull List<net.minecraft.world.entity.player.Player> players
    • worldBorder

      @NotNull protected @NotNull net.minecraft.world.level.border.WorldBorder worldBorder
    • INSTANCE

      public static final SandboxLevel INSTANCE
      Primary SandboxLevel instance that is used ApiStatus.Internally.
  • Constructor Details

    • SandboxLevel

      public SandboxLevel()
    • SandboxLevel

      public SandboxLevel(net.minecraft.world.level.storage.WritableLevelData properties, net.minecraft.resources.ResourceKey<net.minecraft.world.level.Level> registryRef, net.minecraft.core.RegistryAccess registryManager, net.minecraft.core.Holder<net.minecraft.world.level.dimension.DimensionType> dimensionEntry, boolean isClient, boolean debugWorld, long seed, int maxChainedNeighborUpdates)
  • Method Details

    • sendBlockUpdated

      @Virtual public void sendBlockUpdated(net.minecraft.core.BlockPos position, net.minecraft.world.level.block.state.BlockState oldState, net.minecraft.world.level.block.state.BlockState newState, int flags)
      Specified by:
      sendBlockUpdated in class net.minecraft.world.level.Level
    • playSeededSound

      @Virtual public void playSeededSound(@Nullable @Nullable net.minecraft.world.entity.Entity source, double x, double y, double z, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> sound, net.minecraft.sounds.SoundSource category, float volume, float pitch, long speed)
      Specified by:
      playSeededSound in class net.minecraft.world.level.Level
    • playSeededSound

      @Virtual public void playSeededSound(@Nullable @Nullable net.minecraft.world.entity.Entity source, net.minecraft.world.entity.Entity entity, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> sound, net.minecraft.sounds.SoundSource category, float volume, float pitch, long speed)
      Specified by:
      playSeededSound in class net.minecraft.world.level.Level
    • explode

      @Virtual public void explode(@Nullable @Nullable net.minecraft.world.entity.Entity entity, @Nullable @Nullable net.minecraft.world.damagesource.DamageSource damageSource, @Nullable @Nullable net.minecraft.world.level.ExplosionDamageCalculator behavior, double x, double y, double z, float power, boolean createFire, net.minecraft.world.level.Level.ExplosionInteraction explosionSourceType, net.minecraft.core.particles.ParticleOptions smallParticle, net.minecraft.core.particles.ParticleOptions largeParticle, net.minecraft.util.random.WeightedList<net.minecraft.core.particles.ExplosionParticleInfo> blockParticles, net.minecraft.core.Holder<net.minecraft.sounds.SoundEvent> soundEvent)
      Specified by:
      explode in class net.minecraft.world.level.Level
    • gatherChunkSourceStats

      @Virtual public String gatherChunkSourceStats()
      Specified by:
      gatherChunkSourceStats in class net.minecraft.world.level.Level
    • setRespawnData

      @Virtual public void setRespawnData(net.minecraft.world.level.storage.LevelData.RespawnData spawnPoint)
      Specified by:
      setRespawnData in class net.minecraft.world.level.Level
    • getRespawnData

      @Virtual public net.minecraft.world.level.storage.LevelData.RespawnData getRespawnData()
      Specified by:
      getRespawnData in class net.minecraft.world.level.Level
    • getEntity

      @Virtual @Nullable public @Nullable net.minecraft.world.entity.Entity getEntity(int entityId)
      Specified by:
      getEntity in class net.minecraft.world.level.Level
    • dragonParts

      @Virtual public Collection<net.minecraft.world.entity.boss.enderdragon.EnderDragonPart> dragonParts()
      Specified by:
      dragonParts in class net.minecraft.world.level.Level
    • tickRateManager

      @Virtual public net.minecraft.world.TickRateManager tickRateManager()
      Specified by:
      tickRateManager in class net.minecraft.world.level.Level
    • getMapData

      @Virtual @Nullable public @Nullable net.minecraft.world.level.saveddata.maps.MapItemSavedData getMapData(net.minecraft.world.level.saveddata.maps.MapId mapId)
      Specified by:
      getMapData in class net.minecraft.world.level.Level
    • destroyBlockProgress

      @Virtual public void destroyBlockProgress(int entityId, net.minecraft.core.BlockPos position, int progress)
      Specified by:
      destroyBlockProgress in class net.minecraft.world.level.Level
    • getScoreboard

      @Virtual public net.minecraft.world.scores.Scoreboard getScoreboard()
      Specified by:
      getScoreboard in class net.minecraft.world.level.Level
    • recipeAccess

      @Virtual public net.minecraft.world.item.crafting.RecipeAccess recipeAccess()
      Specified by:
      recipeAccess in class net.minecraft.world.level.Level
    • getEntities

      @Virtual protected net.minecraft.world.level.entity.LevelEntityGetter<net.minecraft.world.entity.Entity> getEntities()
      Specified by:
      getEntities in class net.minecraft.world.level.Level
    • clockManager

      @Virtual public net.minecraft.world.clock.ClockManager clockManager()
      Specified by:
      clockManager in class net.minecraft.world.level.Level
    • environmentAttributes

      @Virtual public net.minecraft.world.attribute.EnvironmentAttributeSystem environmentAttributes()
      Specified by:
      environmentAttributes in interface net.minecraft.world.level.LevelReader
      Specified by:
      environmentAttributes in class net.minecraft.world.level.Level
    • potionBrewing

      @Virtual public net.minecraft.world.item.alchemy.PotionBrewing potionBrewing()
      Specified by:
      potionBrewing in class net.minecraft.world.level.Level
    • fuelValues

      @Virtual public net.minecraft.world.level.block.entity.FuelValues fuelValues()
      Specified by:
      fuelValues in class net.minecraft.world.level.Level
    • getChunkSource

      @Virtual public net.minecraft.world.level.chunk.ChunkSource getChunkSource()
    • levelEvent

      @Virtual public void levelEvent(@Nullable @Nullable net.minecraft.world.entity.Entity source, int eventId, net.minecraft.core.BlockPos position, int data)
    • gameEvent

      @Virtual public void gameEvent(net.minecraft.core.Holder<net.minecraft.world.level.gameevent.GameEvent> event, net.minecraft.world.phys.Vec3 emitterPosition, net.minecraft.world.level.gameevent.GameEvent.Context emitter)
    • players

      @Virtual public List<? extends net.minecraft.world.entity.player.Player> players()
    • getUncachedNoiseBiome

      @Virtual public net.minecraft.core.Holder<net.minecraft.world.level.biome.Biome> getUncachedNoiseBiome(int biomeX, int biomeY, int biomeZ)
    • getSeaLevel

      @Virtual public int getSeaLevel()
    • enabledFeatures

      @Virtual public net.minecraft.world.flag.FeatureFlagSet enabledFeatures()
    • getWorldBorder

      @Virtual public net.minecraft.world.level.border.WorldBorder getWorldBorder()
    • getBlockTicks

      @Virtual public net.minecraft.world.ticks.LevelTickAccess<net.minecraft.world.level.block.Block> getBlockTicks()
    • getFluidTicks

      @Virtual public net.minecraft.world.ticks.LevelTickAccess<net.minecraft.world.level.material.Fluid> getFluidTicks()