public class SpawnNPCInteraction extends SimpleBlockInteraction
Class SpawnNPCInteraction. Provides spawnnpcinteraction functionality for the Hytale server.
java.lang.Object > SimpleBlockInteraction > SpawnNPCInteraction
Field Summary
entityId
protected
String
entityId
Field entityId.
spawnOffset
protected
Vector3d
spawnOffset
Field spawnOffset.
spawnYawOffset
protected
float
spawnYawOffset
Field spawnYawOffset.
spawnChance
protected
float
spawnChance
Field spawnChance.
world
final
World
world
Field world.
spawnData
final
SpawnData
spawnData
Field spawnData.
chunkIndex
final
long
chunkIndex
Field chunkIndex.
chunkStore
final
ChunkStore
chunkStore
Field chunkStore.
chunkRef
final
Ref
chunkRef
Field chunkRef.
worldChunkComponent
final
WorldChunk
worldChunkComponent
Field worldChunkComponent.
blockType
final
BlockType
blockType
Field blockType.
blockChunkComponent
final
BlockChunk
blockChunkComponent
Field blockChunkComponent.
section
final
BlockSection
section
Field section.
rotationIndex
final
int
rotationIndex
Field rotationIndex.
rotationTuple
final
RotationTuple
rotationTuple
Field rotationTuple.
position
final
Vector3d
position
Field position.
blockCenter
final
Vector3d
blockCenter
Field blockCenter.
rotation
final
Vector3f
rotation
Field rotation.
commandBuffer
final
CommandBuffer
commandBuffer
Field commandBuffer.
Method Detail
SpawnNPCInteraction
public
public
SpawnNPCInteraction
()
Method SpawnNPCInteraction.
spawnNPC
Method spawnNPC.
- Parameters:
@Nonnull final Storestore@Nonnull final Vector3itargetBlock
computeSpawnData
private
SpawnData
computeSpawnData
(@Nonnull final World world, @Nonnull final Vector3i targetBlock)
Method computeSpawnData.
- Parameters:
@Nonnull final Worldworld@Nonnull final Vector3itargetBlock
SpawnData
public
new
SpawnData
(this.spawnOffset.clone()
Method SpawnData.
- Parameters:
this.spawnOffset.clone(this.spawnOffset.clone(
Vector3f
public
new
Vector3f
(0.0f, (float)
Method Vector3f.
- Parameters:
0.0f0.0f(float(float
interactWithBlock
protected
void
interactWithBlock
(@Nonnull final World world, @Nonnull final CommandBuffer commandBuffer, @Nonnull final InteractionType type, @Nonnull final InteractionContext context, @Nullable final ItemStack itemInHand, @Nonnull final Vector3i targetBlock, @Nonnull final CooldownHandler cooldownHandler)
Method interactWithBlock.
- Parameters:
@Nonnull final Worldworld@Nonnull final CommandBuffercommandBuffer@Nonnull final InteractionTypetype@Nonnull final InteractionContextcontext@Nullable final ItemStackitemInHand@Nonnull final Vector3itargetBlock@Nonnull final CooldownHandlercooldownHandler
simulateInteractWithBlock
protected
void
simulateInteractWithBlock
(@Nonnull final InteractionType type, @Nonnull final InteractionContext context, @Nullable final ItemStack itemInHand, @Nonnull final World world, @Nonnull final Vector3i targetBlock)
Method simulateInteractWithBlock.
- Parameters:
@Nonnull final InteractionTypetype@Nonnull final InteractionContextcontext@Nullable final ItemStackitemInHand@Nonnull final Worldworld@Nonnull final Vector3itargetBlock