Class ReadOnlyClipboard
java.lang.Object
com.fastasyncworldedit.core.extent.clipboard.SimpleClipboard
com.fastasyncworldedit.core.extent.clipboard.ReadOnlyClipboard
- All Implemented Interfaces:
Clipboard
,Extent
,InputExtent
,OutputExtent
,Closeable
,Flushable
,AutoCloseable
,Iterable<BlockVector3>
- Direct Known Subclasses:
WorldCopyClipboard
-
Field Summary
Fields inherited from class com.fastasyncworldedit.core.extent.clipboard.SimpleClipboard
offset
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreateEntity
(Location location, BaseEntity entity) Create an entity at the given location.createEntity
(Location location, BaseEntity entity, UUID uuid) Create an entity at the given location, forcing a UUID onto the entity Only use if you are aware of the consequences of forcing a UUID to an entity.Get a list of all entities.Get the maximum point in the extent.Get the minimum point in the extent.Get the bounding region of this extent.static ReadOnlyClipboard
static ReadOnlyClipboard
static ReadOnlyClipboard
static ReadOnlyClipboard
static ReadOnlyClipboard
static ReadOnlyClipboard
void
removeEntity
(Entity entity) Remove entity from clipboard.boolean
boolean
setBiome
(BlockVector3 position, BiomeType biome) Set the biome.<B extends BlockStateHolder<B>>
booleansetBlock
(int x, int y, int z, B block) boolean
tile
(int x, int y, int z, FaweCompoundTag tag) Sets a tile/block entity at the given location.Methods inherited from class com.fastasyncworldedit.core.extent.clipboard.SimpleClipboard
getArea, getDimensions, getHeight, getLength, getOrigin, getVolume, getWidth, setOffset, setOrigin
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.sk89q.worldedit.extent.clipboard.Clipboard
apply, close, flush, getURI, hasBiomes, iterator, iterator, iterator2d, paste, paste, paste, paste, paste, paste, save, save, transform
Methods inherited from interface com.sk89q.worldedit.extent.Extent
addCaves, addOre, addOres, addPostProcessor, addProcessor, addSchems, apply, cancel, center, commit, contains, contains, countBlocks, countBlocks, disableHistory, disableQueue, enableHistory, enableQueue, generate, getBlockDistribution, getBlockDistributionWithData, getEntities, getHighestTerrainBlock, getHighestTerrainBlock, getMaxY, getMinY, getNearestSurfaceLayer, getNearestSurfaceTerrainBlock, getNearestSurfaceTerrainBlock, getNearestSurfaceTerrainBlock, getNearestSurfaceTerrainBlock, getNearestSurfaceTerrainBlock, isQueueEnabled, isWorld, lazyCopy, regenerateChunk, relight, relightBlock, relightSky, removeEntity, replaceBlocks, replaceBlocks, replaceBlocks, setBlocks, setBlocks, setBlocks, spawnResource
Methods inherited from interface com.sk89q.worldedit.extent.InputExtent
getBiome, getBiome, getBiomeType, getBlock, getBlock, getBrightness, getBrightness, getEmittedLight, getEmittedLight, getFullBlock, getFullBlock, getHeightMap, getOpacity, getOpacity, getSkyLight, getSkyLight
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface com.sk89q.worldedit.extent.OutputExtent
fullySupports3DBiomes, setBiome, setBlock, setBlockLight, setBlockLight, setHeightMap, setSkyLight, setSkyLight, setTile
-
Field Details
-
region
-
-
Constructor Details
-
ReadOnlyClipboard
-
-
Method Details
-
of
-
of
-
of
-
of
public static ReadOnlyClipboard of(Extent extent, Region region, boolean copyEntities, boolean copyBiomes) -
of
-
of
public static ReadOnlyClipboard of(Supplier<Extent> supplier, Region region, boolean copyEntities, boolean copyBiomes) -
getMinimumPoint
Description copied from interface:Extent
Get the minimum point in the extent.If the extent is unbounded, then a large (negative) value may be returned.
- Specified by:
getMinimumPoint
in interfaceExtent
- Overrides:
getMinimumPoint
in classSimpleClipboard
- Returns:
- the minimum point
-
getMaximumPoint
Description copied from interface:Extent
Get the maximum point in the extent.If the extent is unbounded, then a large (positive) value may be returned.
- Specified by:
getMaximumPoint
in interfaceExtent
- Overrides:
getMaximumPoint
in classSimpleClipboard
- Returns:
- the maximum point
-
getRegion
Description copied from interface:Clipboard
Get the bounding region of this extent.Implementations should return a copy of the region.
- Specified by:
getRegion
in interfaceClipboard
- Overrides:
getRegion
in classSimpleClipboard
- Returns:
- the bounding region
-
setBiome
-
setBiome
Description copied from interface:OutputExtent
Set the biome.As implementation varies per Minecraft version, this may set more than this position's biome. On versions prior to 1.15, this will set the entire column. On later versions it will set the 4x4x4 cube.
- Parameters:
position
- the (x, y, z) location to set the biome atbiome
- the biome to set to- Returns:
- true if the biome was successfully set (return value may not be accurate)
-
getEntities
Description copied from interface:Extent
Get a list of all entities.If the extent is not wholly loaded (i.e. a world being simulated in the game will not have every chunk loaded), then this list may not be incomplete.
- Returns:
- a list of entities
-
setBlock
-
tile
Description copied from interface:OutputExtent
Sets a tile/block entity at the given location.- Parameters:
x
- the x positiony
- the y positionz
- the z positiontag
- the tile/block entity to set- Returns:
true
if the tile/block entity was placed
-
createEntity
Description copied from interface:Extent
Create an entity at the given location.- Parameters:
location
- the locationentity
- the entity- Returns:
- a reference to the created entity, or null if the entity could not be created
-
createEntity
Description copied from interface:Extent
Create an entity at the given location, forcing a UUID onto the entity Only use if you are aware of the consequences of forcing a UUID to an entity.- Parameters:
location
- the locationentity
- the entityuuid
- UUID to force the entity to have- Returns:
- a reference to the created entity, or null if the entity could not be created
-
removeEntity
Description copied from interface:Clipboard
Remove entity from clipboard.
-