Package com.sk89q.worldedit.internal.wna
Interface WorldNativeAccess<NC,NBS,NP>
- Type Parameters:
NC
- the native chunk typeNBS
- the native block state typeNP
- the native position type
public interface WorldNativeAccess<NC,NBS,NP>
Natively access and perform operations on the world.
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
applySideEffects
(BlockVector3 position, BlockState previousType, SideEffectSet sideEffectSet) void
flush()
getBlockState
(NC chunk, NP position) getChunk
(int x, int z) getPosition
(int x, int y, int z) getValidBlockForPosition
(NBS block, NP position) boolean
isChunkTicking
(NC chunk) default void
markAndNotifyBlock
(NP pos, NC chunk, NBS oldState, NBS newState, SideEffectSet sideEffectSet) This is a heavily modified function stripped from MC to apply WorldEdit-modifications.void
markBlockChanged
(NC chunk, NP position) void
notifyBlockUpdate
(NC chunk, NP position, NBS oldState, NBS newState) void
notifyNeighbors
(NP pos, NBS oldState, NBS newState) void
onBlockStateChange
(NP pos, NBS oldState, NBS newState) default <B extends BlockStateHolder<B>>
booleansetBlock
(BlockVector3 position, B block, SideEffectSet sideEffects) setBlockState
(NC chunk, NP position, NBS state) default void
setCurrentSideEffectSet
(SideEffectSet sideEffectSet) Receive the current side-effect set from the high level call.toNative
(BlockState state) void
updateLightingForBlock
(NP position) void
updateNeighbors
(NP pos, NBS oldState, NBS newState, int recursionLimit) boolean
updateTileEntity
(NP position, com.sk89q.worldedit.util.nbt.CompoundBinaryTag tag)
-
Method Details
-
setBlock
default <B extends BlockStateHolder<B>> boolean setBlock(BlockVector3 position, B block, SideEffectSet sideEffects) throws WorldEditException - Throws:
WorldEditException
-
applySideEffects
default void applySideEffects(BlockVector3 position, BlockState previousType, SideEffectSet sideEffectSet) -
setCurrentSideEffectSet
Receive the current side-effect set from the high level call.This allows the implementation to branch on the side-effects internally.
- Parameters:
sideEffectSet
- the set of side-effects
-
getChunk
-
toNative
-
getBlockState
-
setBlockState
-
getValidBlockForPosition
-
getPosition
-
updateLightingForBlock
-
updateTileEntity
-
notifyBlockUpdate
-
isChunkTicking
-
markBlockChanged
-
notifyNeighbors
-
updateNeighbors
-
onBlockStateChange
-
markAndNotifyBlock
default void markAndNotifyBlock(NP pos, NC chunk, NBS oldState, NBS newState, SideEffectSet sideEffectSet) This is a heavily modified function stripped from MC to apply WorldEdit-modifications.See Forge's World.markAndNotifyBlock
-
flush
void flush()
-