Package org.spongepowered.api.entity
Interface EntitySnapshot.Builder
-
- All Superinterfaces:
AbstractBuilder<EntitySnapshot>,Buildable.Builder<EntitySnapshot>,Builder<EntitySnapshot,EntitySnapshot.Builder>,CopyableBuilder<EntitySnapshot,EntitySnapshot.Builder>,DataBuilder<EntitySnapshot>,DataHolderBuilder<EntitySnapshot,EntitySnapshot.Builder>,DataHolderBuilder.Immutable<EntitySnapshot,EntitySnapshot.Builder>,ResettableBuilder<EntitySnapshot,EntitySnapshot.Builder>
- Enclosing interface:
- EntitySnapshot
public static interface EntitySnapshot.Builder extends DataHolderBuilder.Immutable<EntitySnapshot,EntitySnapshot.Builder>, DataBuilder<EntitySnapshot>
AnDataHolderBuilder.Immutablefor buildingEntitySnapshots. The requirements
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.spongepowered.api.data.DataHolderBuilder
DataHolderBuilder.Immutable<H extends DataHolder.Immutable<H>,B extends DataHolderBuilder.Immutable<H,B>>, DataHolderBuilder.Mutable<H extends DataHolder.Mutable,B extends DataHolderBuilder.Mutable<H,B>>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description EntitySnapshot.Builderfrom(Entity entity)Copies over data from anEntity.EntitySnapshot.Builderposition(Vector3d position)Sets the coordinates of thisEntitySnapshotfrom aVector3i.default EntitySnapshot.Buildertype(Supplier<? extends EntityType<?>> entityType)Sets theEntityTypefor thisEntitySnapshot.EntitySnapshot.Buildertype(EntityType<?> entityType)Sets theEntityTypefor thisEntitySnapshot.EntitySnapshot.Builderworld(ServerWorldProperties worldProperties)Sets theWorldPropertiesfor thisEntitySnapshot.-
Methods inherited from interface net.kyori.adventure.util.Buildable.Builder
build
-
Methods inherited from interface org.spongepowered.api.data.persistence.DataBuilder
build
-
-
-
-
Method Detail
-
world
EntitySnapshot.Builder world(ServerWorldProperties worldProperties)
Sets theWorldPropertiesfor thisEntitySnapshot.This is used to grab the
UUIDof the World for this snapshot.- Parameters:
worldProperties- The WorldProperties- Returns:
- This builder, for chaining
-
type
default EntitySnapshot.Builder type(Supplier<? extends EntityType<?>> entityType)
Sets theEntityTypefor thisEntitySnapshot.- Parameters:
entityType- The EntityType- Returns:
- This builder, for chaining
-
type
EntitySnapshot.Builder type(EntityType<?> entityType)
Sets theEntityTypefor thisEntitySnapshot.- Parameters:
entityType- The EntityType- Returns:
- This builder, for chaining
-
position
EntitySnapshot.Builder position(Vector3d position)
Sets the coordinates of thisEntitySnapshotfrom aVector3i.- Parameters:
position- The Vector3i representing the coordinates- Returns:
- This builder, for chaining
-
from
EntitySnapshot.Builder from(Entity entity)
Copies over data from anEntity.- Parameters:
entity- The Entity- Returns:
- This builder, for chaining
-
-