Package net.minecraft.util
Class SpawnUtil
java.lang.Object
net.minecraft.util.SpawnUtil
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static boolean
moveToPossibleSpawnPosition
(ServerLevel level, int yOffset, BlockPos.MutableBlockPos pos, SpawnUtil.Strategy strategy) trySpawnMob
(EntityType<T> entityType, MobSpawnType spawnType, ServerLevel level, BlockPos pos, int attempts, int spread, int yOffset, SpawnUtil.Strategy strategy)
-
Constructor Details
-
SpawnUtil
public SpawnUtil()
-
-
Method Details
-
trySpawnMob
public static <T extends Mob> Optional<T> trySpawnMob(EntityType<T> entityType, MobSpawnType spawnType, ServerLevel level, BlockPos pos, int attempts, int spread, int yOffset, SpawnUtil.Strategy strategy) -
moveToPossibleSpawnPosition
private static boolean moveToPossibleSpawnPosition(ServerLevel level, int yOffset, BlockPos.MutableBlockPos pos, SpawnUtil.Strategy strategy)
-