public static interface ImmutableMobSpawnerData.ImmutableNextEntityToSpawnValue extends ImmutableValue<WeightedEntity>
Value
dealing with the next
WeightedEntity
such that the next Entity
to spawn may
be pulled from the owning ImmutableMobSpawnerData.possibleEntitiesToSpawn()
with a
default Random
, or it may be custom defined on a case by
case basis.ImmutableMobSpawnerData.ImmutableNextEntityToSpawnValue with(EntityType type, @Nullable Collection<DataManipulator<?,?>> additionalProperties)
ImmutableMobSpawnerData.ImmutableNextEntityToSpawnValue
with the
provided EntityType
and Collection
of
DataManipulator
s.ImmutableMobSpawnerData.ImmutableNextEntityToSpawnValue with(WeightedEntity value)
ImmutableValue
ImmutableValue
with the given E
typed
value, such that if the owning ValueContainer
is immutable, the
ValueContainer
too is recreated as a new instance with the new
ImmutableValue
.with
in interface ImmutableValue<WeightedEntity>
value
- The value to replaceValueContainer
, a new instance if it too is
immutableImmutableMobSpawnerData.ImmutableNextEntityToSpawnValue transform(Function<WeightedEntity,WeightedEntity> function)
ImmutableValue
ImmutableValue
and
applies the given Function
onto that value, after which, the
product is sent to a new ImmutableValue
replacing this one.
If the ValueContainer
too is immutable, a new instance of
the ValueContainer
may be created. If the ValueContainer
is mutable, the same instance of the ValueContainer
is retained.
transform
in interface ImmutableValue<WeightedEntity>
function
- The function to apply onto the existing valueValueContainer
, a new instance if it too is
immutableMobSpawnerData.NextEntityToSpawnValue asMutable()
ImmutableValue
Value
for this ImmutableValue
.asMutable
in interface ImmutableValue<WeightedEntity>