public class SpreadPlayersCommand extends Object
Modifier and Type | Class and Description |
---|---|
(package private) static class |
SpreadPlayersCommand.Pile |
Modifier and Type | Field and Description |
---|---|
private static com.mojang.brigadier.exceptions.Dynamic4CommandExceptionType |
FAILED_ENTITIES_EXCEPTION |
private static com.mojang.brigadier.exceptions.Dynamic4CommandExceptionType |
FAILED_TEAMS_EXCEPTION |
Constructor and Description |
---|
SpreadPlayersCommand() |
Modifier and Type | Method and Description |
---|---|
private static int |
execute(ServerCommandSource source,
Vec2f center,
float spreadDistance,
float maxRange,
int int2,
boolean bool,
Collection<? extends Entity> collection) |
private static double |
getMinDistance(Collection<? extends Entity> entities,
ServerWorld world,
SpreadPlayersCommand.Pile[] piles,
int int2,
boolean bool) |
private static int |
getPileCountRespectingTeams(Collection<? extends Entity> entities) |
private static SpreadPlayersCommand.Pile[] |
makePiles(Random random,
int count,
double minX,
double minZ,
double maxX,
double maxZ) |
static void |
register(com.mojang.brigadier.CommandDispatcher<ServerCommandSource> dispatcher) |
private static void |
spread(Vec2f center,
double spreadDistance,
ServerWorld world,
Random random,
double minX,
double minZ,
double maxX,
double maxZ,
int int2,
SpreadPlayersCommand.Pile[] pile,
boolean bool) |
private static final com.mojang.brigadier.exceptions.Dynamic4CommandExceptionType FAILED_TEAMS_EXCEPTION
private static final com.mojang.brigadier.exceptions.Dynamic4CommandExceptionType FAILED_ENTITIES_EXCEPTION
public static void register(com.mojang.brigadier.CommandDispatcher<ServerCommandSource> dispatcher)
private static int execute(ServerCommandSource source, Vec2f center, float spreadDistance, float maxRange, int int2, boolean bool, Collection<? extends Entity> collection)
private static int getPileCountRespectingTeams(Collection<? extends Entity> entities)
private static void spread(Vec2f center, double spreadDistance, ServerWorld world, Random random, double minX, double minZ, double maxX, double maxZ, int int2, SpreadPlayersCommand.Pile[] pile, boolean bool) throws com.mojang.brigadier.exceptions.CommandSyntaxException
com.mojang.brigadier.exceptions.CommandSyntaxException
private static double getMinDistance(Collection<? extends Entity> entities, ServerWorld world, SpreadPlayersCommand.Pile[] piles, int int2, boolean bool)
private static SpreadPlayersCommand.Pile[] makePiles(Random random, int count, double minX, double minZ, double maxX, double maxZ)