Class LegendarySpawner
java.lang.Object
com.pixelmonmod.pixelmon.api.spawning.AbstractSpawner
com.pixelmonmod.pixelmon.api.spawning.archetypes.spawners.TickingSpawner
com.pixelmonmod.pixelmon.spawning.LegendarySpawner
The spawner responsible for legendary and mega-boss spawning.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classNested classes/interfaces inherited from class com.pixelmonmod.pixelmon.api.spawning.archetypes.spawners.TickingSpawner
TickingSpawner.TickingSpawnerBuilder<T extends TickingSpawner>Nested classes/interfaces inherited from class com.pixelmonmod.pixelmon.api.spawning.AbstractSpawner
AbstractSpawner.SpawnerBuilder<T extends AbstractSpawner> -
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanWhether or not this fires the legendary events onto the Pixelmon bus.intintintList<SpawnAction<?>>intFields inherited from class com.pixelmonmod.pixelmon.api.spawning.archetypes.spawners.TickingSpawner
capacity, lastCycleTime, minDistBetweenSpawns, nextSpawnTime, spawnFrequency, spawnLocationCalculator, spawnsPerPassFields inherited from class com.pixelmonmod.pixelmon.api.spawning.AbstractSpawner
cacheSets, checkSpawns, conditions, isBusy, lastSpawnTime, name, rarityMultipliers, rarityTweaks, selectionAlgorithm, spawnedTracker, spawnSets, tweaks -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoLegendarySpawn(net.minecraft.server.level.ServerPlayer target) Attempts to perform a legendary spawn at the given target.static voidfillNearby(ArrayList<net.minecraft.server.level.ServerPlayer> allPlayers, ArrayList<net.minecraft.server.level.ServerPlayer> cluster, net.minecraft.server.level.ServerPlayer focus) voidforcefullySpawn(net.minecraft.server.level.ServerPlayer onlyFocus) intGets the number of passes.List<SpawnAction<? extends net.minecraft.world.entity.Entity>>getSpawns(int pass) Performs a specific pass, where pass index starts at zero, returning a list ofSpawnActions that should execute.Methods inherited from class com.pixelmonmod.pixelmon.api.spawning.archetypes.spawners.TickingSpawner
canSpawn, doPass, hasCapacity, onSpawnEnded, shouldDoSpawningMethods inherited from class com.pixelmonmod.pixelmon.api.spawning.AbstractSpawner
calculateSpatialData, fits, getCondition, getSuitableSpawns, getSuitableSpawnsForBiome, getTrackedBlockCollection, getTweak, getWeightedSpawnInfo, hasCondition, hasTweak
-
Field Details
-
minDistFromCentre
public int minDistFromCentre -
maxDistFromCentre
public int maxDistFromCentre -
horizontalSliceRadius
public int horizontalSliceRadius -
verticalSliceRadius
public int verticalSliceRadius -
possibleSpawns
-
firesChooseEvent
public boolean firesChooseEventWhether or not this fires the legendary events onto the Pixelmon bus. This is also used to decide which config options to use for spawning frequency and chance.
-
-
Constructor Details
-
LegendarySpawner
-
-
Method Details
-
fillNearby
-
forcefullySpawn
public void forcefullySpawn(@Nullable net.minecraft.server.level.ServerPlayer onlyFocus) -
getSpawns
Description copied from class:TickingSpawnerPerforms a specific pass, where pass index starts at zero, returning a list ofSpawnActions that should execute. Null or empty lists are acceptable. An implementation that doesn't use passes will ignore this parameter.- Specified by:
getSpawnsin classTickingSpawner
-
doLegendarySpawn
public CompletableFuture<List<SpawnAction<?>>> doLegendarySpawn(net.minecraft.server.level.ServerPlayer target) Attempts to perform a legendary spawn at the given target. This could fail and return null. -
getNumPasses
public int getNumPasses()Description copied from class:TickingSpawnerGets the number of passes. An implementation that doesn't use passes will return 1.- Specified by:
getNumPassesin classTickingSpawner
-