类 EntitySelector
java.lang.Object
net.minecraft.commands.arguments.selector.EntitySelector
-
字段概要
字段修饰符和类型字段说明private final AABB
private static final EntityTypeTest<Entity,
?> private final boolean
private final UUID
private final boolean
static final int
private final int
private final BiConsumer<Vec3,
List<? extends Entity>> static final BiConsumer<Vec3,
List<? extends Entity>> private final String
private final MinMaxBounds.Doubles
private final EntityTypeTest<Entity,
?> private final boolean
private final boolean
-
构造器概要
构造器构造器说明EntitySelector
(int pMaxResults, boolean pIncludeEntities, boolean pWorldLimited, Predicate<Entity> pPredicate, MinMaxBounds.Doubles pRange, Function<Vec3, Vec3> pPositions, AABB pAabb, BiConsumer<Vec3, List<? extends Entity>> pOrder, boolean pCurrentEntity, String pPlayerName, UUID pEntityUUID, EntityType<?> pType, boolean pUsesSelector) -
方法概要
修饰符和类型方法说明private void
addEntities
(List<Entity> pResult, ServerLevel pLevel, Vec3 pPos, Predicate<Entity> pPredicate) private void
checkPermissions
(CommandSourceStack pSource) findEntities
(CommandSourceStack pSource) findEntitiesRaw
(CommandSourceStack p_251934_) findPlayers
(CommandSourceStack pSource) findSingleEntity
(CommandSourceStack pSource) findSinglePlayer
(CommandSourceStack pSource) int
getPredicate
(Vec3 pPos) private int
boolean
boolean
boolean
static Component
sortAndLimit
(Vec3 pPos, List<T> pEntities) boolean
-
字段详细资料
-
INFINITE
public static final int INFINITE- 另请参阅:
-
ORDER_ARBITRARY
-
ANY_TYPE
-
maxResults
private final int maxResults -
includesEntities
private final boolean includesEntities -
worldLimited
private final boolean worldLimited -
predicate
-
range
-
position
-
aabb
-
order
-
currentEntity
private final boolean currentEntity -
playerName
-
entityUUID
-
type
-
usesSelector
private final boolean usesSelector
-
-
构造器详细资料
-
EntitySelector
public EntitySelector(int pMaxResults, boolean pIncludeEntities, boolean pWorldLimited, Predicate<Entity> pPredicate, MinMaxBounds.Doubles pRange, Function<Vec3, Vec3> pPositions, @Nullable AABB pAabb, BiConsumer<Vec3, List<? extends Entity>> pOrder, boolean pCurrentEntity, @Nullable String pPlayerName, @Nullable UUID pEntityUUID, @Nullable EntityType<?> pType, boolean pUsesSelector)
-
-
方法详细资料
-
getMaxResults
public int getMaxResults() -
includesEntities
public boolean includesEntities() -
isSelfSelector
public boolean isSelfSelector() -
isWorldLimited
public boolean isWorldLimited() -
usesSelector
public boolean usesSelector() -
checkPermissions
private void checkPermissions(CommandSourceStack pSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
findSingleEntity
public Entity findSingleEntity(CommandSourceStack pSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
findEntities
public List<? extends Entity> findEntities(CommandSourceStack pSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
findEntitiesRaw
private List<? extends Entity> findEntitiesRaw(CommandSourceStack p_251934_) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
addEntities
-
getResultLimit
private int getResultLimit() -
findSinglePlayer
public ServerPlayer findSinglePlayer(CommandSourceStack pSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
findPlayers
public List<ServerPlayer> findPlayers(CommandSourceStack pSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getPredicate
-
sortAndLimit
-
joinNames
-