java.lang.Object
net.neoforged.bus.api.Event
com.pixelmonmod.pixelmon.api.events.spawning.SpawnEvent
All Implemented Interfaces:
net.neoforged.bus.api.ICancellableEvent

public class SpawnEvent extends net.neoforged.bus.api.Event implements net.neoforged.bus.api.ICancellableEvent
Event fired when an AbstractSpawner attempts to perform a SpawnAction. Cancelling this event will prevent the Pokémon or NPC or whatever from spawning.
  • Field Details

    • spawner

      public final AbstractSpawner spawner
      The AbstractSpawner attempting to do the spawn.
    • action

      public final SpawnAction<? extends net.minecraft.world.entity.Entity> action
      The specific information about the spawn.
  • Constructor Details