java.lang.Object
com.pixelmonmod.pixelmon.api.spawning.SpawnAction<PixelmonEntity>
com.pixelmonmod.pixelmon.api.spawning.archetypes.entities.pokemon.SpawnActionPokemon

public class SpawnActionPokemon extends SpawnAction<PixelmonEntity>
SpawnAction for Pokémon entities.
  • Field Details

  • Constructor Details

  • Method Details

    • createEntity

      protected PixelmonEntity createEntity()
      Description copied from class: SpawnAction
      Creates the entity and returns the result. Returning null if the spawn should fail is safe in default implementations.
      Specified by:
      createEntity in class SpawnAction<PixelmonEntity>
    • doSpawn

      public PixelmonEntity doSpawn(AbstractSpawner spawner)
      Description copied from class: SpawnAction
      Does the spawn of this entity at the stored SpawnLocation on behalf of the given AbstractSpawner. This can return null if the spawn should fail at any point, and the Better Spawner will interpret this as a cancelled spawn without consequences.

      Overrides of this method are strongly advised to call the super due to important functions that occur here.

      Overrides:
      doSpawn in class SpawnAction<PixelmonEntity>
    • getPokemonLevelBasedOnDistance

      public static int getPokemonLevelBasedOnDistance(SpawnLocation spawnLocation)
      Gets the base pokemonLevel for a Pokémon spawning at this location according to the spawnLevelsByDistance config option.