Class HighlightedBlockSpawner
java.lang.Object
nl.pim16aap2.animatedarchitecture.core.api.HighlightedBlockSpawner
- Direct Known Subclasses:
HighlightedBlockSpawnerSpigot
Represents a highlighted animated block. These can be useful for highlighting locations and structures.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classThe default builder implementation for highlighted blocks. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a new builder for a highlighted block.protected abstract IExecutorprotected abstract Optional<IHighlightedBlock> spawnHighlightedBlock(IPlayer player, IWorld world, @Nullable Duration duration, RotatedPosition rotatedPosition, Color color) voidspawnHighlightedBlocks(IStructureConst structure, IPlayer player, @Nullable Duration duration) Spawns the highlighted blocks required to highlight a structure.voidspawnHighlightedBlocks(Structure structure, IPlayer player, @Nullable Duration duration) Spawns the highlighted blocks required to highlight a structure.
-
Constructor Details
-
HighlightedBlockSpawner
public HighlightedBlockSpawner()
-
-
Method Details
-
spawnHighlightedBlock
protected abstract Optional<IHighlightedBlock> spawnHighlightedBlock(IPlayer player, IWorld world, @Nullable Duration duration, RotatedPosition rotatedPosition, Color color) -
spawnHighlightedBlocks
public void spawnHighlightedBlocks(IStructureConst structure, IPlayer player, @Nullable Duration duration) Spawns the highlighted blocks required to highlight a structure.- Parameters:
structure- The structure to highlight.player- TheIPlayerfor whom to highlight the structure.duration- The amount of time the highlighted blocks should be visible for.
-
spawnHighlightedBlocks
public void spawnHighlightedBlocks(Structure structure, IPlayer player, @Nullable Duration duration) Spawns the highlighted blocks required to highlight a structure.- Parameters:
structure- The structure to highlight.player- TheIPlayerfor whom to highlight the structure.duration- The amount of time the highlighted blocks should be visible for.
-
getExecutor
-
builder
Creates a new builder for a highlighted block.- Returns:
- A new builder for a highlighted block.
-