Contents
- Description
- Nested Class Summary
- Field Summary
- Constructor Summary
- Method Summary
- Constructor Details
- Method Details
- getMaxDistanceUnsorted()
- getMaxDistanceSorted()
- getMaxDistanceAvoidance()
- getSearchRadius()
- getBucketRanges()
- reset()
- requireDistanceSorted(int)
- requireDistanceUnsorted(int)
- requireDistanceAvoidance(int)
- finalizeConfiguration()
- add(Ref, Vector3d, CommandBuffer)
- forEachEntity(DoubleQuadObjectConsumer, T, U, V, double, ComponentAccessor)
- forEachEntityUnordered(double, QuadPredicate, QuadConsumer, T, U, V, R, ComponentAccessor)
- forEachEntityAvoidance(Set, TriConsumer, T, CommandBuffer)
- forEachEntityAvoidance(Set, QuadConsumer, T, U, CommandBuffer)
- countEntitiesInRange(double, double, int, QuadPredicate, S, T, ComponentAccessor)
- getClosestEntityInRange(double, double, Predicate, ComponentAccessor)
- getClosestEntityInRange(Ref, double, double, QuadPredicate, ExecutionSupport, S, T, ComponentAccessor)
- getClosestEntityInRangeProjected(Ref, Ref, MotionController, double, double, QuadPredicate, ExecutionSupport, S, T, ComponentAccessor)
- testAnyEntity(double, QuadObjectDoublePredicate, S, T, ComponentAccessor)
- testAnyEntityDistanceSquared(double, QuadObjectDoublePredicate, S, T, ComponentAccessor)
- testAnyEntityDistanceSquared(double, QuadObjectDoublePredicate, S, T, double, ComponentAccessor)
Class EntityList
java.lang.Object
com.hypixel.hytale.common.collection.BucketList<Ref<EntityStore>>
com.hypixel.hytale.server.npc.role.support.EntityList
-
Nested Class Summary
Nested classes/interfaces inherited from class BucketList
BucketList.Bucket<E>, BucketList.SortBufferProvider -
Field Summary
Fields inherited from class BucketList
CLOSER_TO_SELF, INITIAL_BUCKET_ITEM_ARRAY_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionEntityList(BucketItemPool<Ref<EntityStore>> holderPool, BiPredicate<Ref<EntityStore>, ComponentAccessor<EntityStore>> validator) -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(Ref<EntityStore> ref, org.joml.Vector3d parentPosition, CommandBuffer<EntityStore> commandBuffer) <S,T> int countEntitiesInRange(double minRange, double maxRange, int maxCount, QuadPredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> filter, S s, T t, ComponentAccessor<EntityStore> componentAccessor) void<T,U, V> void forEachEntity(DoubleQuadObjectConsumer<Ref<EntityStore>, T, U, V> consumer, T t, U u, V v, double d, ComponentAccessor<EntityStore> componentAccessor) <T,U> void forEachEntityAvoidance(Set<Ref<EntityStore>> ignoredEntitiesForAvoidance, QuadConsumer<Ref<EntityStore>, T, U, CommandBuffer<EntityStore>> consumer, T t, U u, CommandBuffer<EntityStore> commandBuffer) <T> voidforEachEntityAvoidance(Set<Ref<EntityStore>> ignoredEntitiesForAvoidance, TriConsumer<Ref<EntityStore>, T, CommandBuffer<EntityStore>> consumer, T t, CommandBuffer<EntityStore> commandBuffer) <T,U, V, R> void forEachEntityUnordered(double maxDistance, QuadPredicate<Ref<EntityStore>, T, U, ComponentAccessor<EntityStore>> predicate, QuadConsumer<Ref<EntityStore>, T, V, R> consumer, T t, U u, V v, R r, ComponentAccessor<EntityStore> componentAccessor) it.unimi.dsi.fastutil.ints.IntArrayListgetClosestEntityInRange(double minRange, double maxRange, Predicate<Ref<EntityStore>> filter, ComponentAccessor<EntityStore> componentAccessor) <S,T> Ref <EntityStore> getClosestEntityInRange(Ref<EntityStore> ignoredEntityReference, double minRange, double maxRange, QuadPredicate<S, Ref<EntityStore>, ExecutionSupport, T> filter, ExecutionSupport executionSupport, S s, T t, ComponentAccessor<EntityStore> componentAccessor) <S,T> Ref <EntityStore> getClosestEntityInRangeProjected(Ref<EntityStore> parentRef, Ref<EntityStore> ignoredEntityReference, MotionController motionController, double minRange, double maxRange, QuadPredicate<S, Ref<EntityStore>, ExecutionSupport, T> filter, ExecutionSupport executionSupport, S s, T t, ComponentAccessor<EntityStore> componentAccessor) intintintintintrequireDistanceAvoidance(int value) intrequireDistanceSorted(int value) intrequireDistanceUnsorted(int value) voidreset()<S,T> boolean testAnyEntity(double maxDistance, QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, ComponentAccessor<EntityStore> componentAccessor) <S,T> boolean testAnyEntityDistanceSquared(double maxDistanceSquared, QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, double d, ComponentAccessor<EntityStore> componentAccessor) <S,T> boolean testAnyEntityDistanceSquared(double maxDistanceSquared, QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, ComponentAccessor<EntityStore> componentAccessor) Methods inherited from class BucketList
add, addBucketDistance, addBucketDistance, clear, configure, configure, configureWithPresortedArray, configureWithPreSortedArray, configureWithPreSortedArray, getBucket, getBucketCount, getClosestInRange, getFirstBucketIndex, getLastBucketIndex, setBucketItemPool
-
Constructor Details
-
EntityList
public EntityList(@Nullable BucketItemPool<Ref<EntityStore>> holderPool, @Nonnull BiPredicate<Ref<EntityStore>, ComponentAccessor<EntityStore>> validator)
-
-
Method Details
-
getMaxDistanceUnsorted
public int getMaxDistanceUnsorted() -
getMaxDistanceSorted
public int getMaxDistanceSorted() -
getMaxDistanceAvoidance
public int getMaxDistanceAvoidance() -
getSearchRadius
public int getSearchRadius() -
getBucketRanges
public it.unimi.dsi.fastutil.ints.IntArrayList getBucketRanges() -
reset
public void reset()- Overrides:
resetin classBucketList<Ref<EntityStore>>
-
requireDistanceSorted
public int requireDistanceSorted(int value) -
requireDistanceUnsorted
public int requireDistanceUnsorted(int value) -
requireDistanceAvoidance
public int requireDistanceAvoidance(int value) -
finalizeConfiguration
public void finalizeConfiguration() -
add
public void add(@Nonnull Ref<EntityStore> ref, @Nonnull org.joml.Vector3d parentPosition, @Nonnull CommandBuffer<EntityStore> commandBuffer) -
forEachEntity
public <T,U, void forEachEntityV> (@Nonnull DoubleQuadObjectConsumer<Ref<EntityStore>, T, U, V> consumer, T t, U u, V v, double d, ComponentAccessor<EntityStore> componentAccessor) -
forEachEntityUnordered
public <T,U, void forEachEntityUnorderedV, R> (double maxDistance, @Nonnull QuadPredicate<Ref<EntityStore>, T, U, ComponentAccessor<EntityStore>> predicate, @Nonnull QuadConsumer<Ref<EntityStore>, T, V, R> consumer, T t, U u, V v, R r, ComponentAccessor<EntityStore> componentAccessor) -
forEachEntityAvoidance
public <T> void forEachEntityAvoidance(@Nonnull Set<Ref<EntityStore>> ignoredEntitiesForAvoidance, @Nonnull TriConsumer<Ref<EntityStore>, T, CommandBuffer<EntityStore>> consumer, T t, CommandBuffer<EntityStore> commandBuffer) -
forEachEntityAvoidance
public <T,U> void forEachEntityAvoidance(@Nonnull Set<Ref<EntityStore>> ignoredEntitiesForAvoidance, @Nonnull QuadConsumer<Ref<EntityStore>, T, U, CommandBuffer<EntityStore>> consumer, T t, U u, CommandBuffer<EntityStore> commandBuffer) -
countEntitiesInRange
public <S,T> int countEntitiesInRange(double minRange, double maxRange, int maxCount, @Nonnull QuadPredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> filter, S s, T t, ComponentAccessor<EntityStore> componentAccessor) -
getClosestEntityInRange
@Nullable public Ref<EntityStore> getClosestEntityInRange(double minRange, double maxRange, @Nonnull Predicate<Ref<EntityStore>> filter, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
getClosestEntityInRange
@Nullable public <S,T> Ref<EntityStore> getClosestEntityInRange(@Nullable Ref<EntityStore> ignoredEntityReference, double minRange, double maxRange, @Nonnull QuadPredicate<S, Ref<EntityStore>, ExecutionSupport, T> filter, ExecutionSupport executionSupport, S s, T t, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
getClosestEntityInRangeProjected
@Nullable public <S,T> Ref<EntityStore> getClosestEntityInRangeProjected(@Nonnull Ref<EntityStore> parentRef, @Nullable Ref<EntityStore> ignoredEntityReference, @Nonnull MotionController motionController, double minRange, double maxRange, @Nonnull QuadPredicate<S, Ref<EntityStore>, ExecutionSupport, T> filter, ExecutionSupport executionSupport, S s, T t, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
testAnyEntity
public <S,T> boolean testAnyEntity(double maxDistance, @Nonnull QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, ComponentAccessor<EntityStore> componentAccessor) -
testAnyEntityDistanceSquared
public <S,T> boolean testAnyEntityDistanceSquared(double maxDistanceSquared, @Nonnull QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, ComponentAccessor<EntityStore> componentAccessor) -
testAnyEntityDistanceSquared
public <S,T> boolean testAnyEntityDistanceSquared(double maxDistanceSquared, @Nonnull QuadObjectDoublePredicate<S, Ref<EntityStore>, T, ComponentAccessor<EntityStore>> predicate, S s, T t, double d, ComponentAccessor<EntityStore> componentAccessor)
-