Class PixelmonFaintEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
com.pixelmonmod.pixelmon.api.events.PixelmonFaintEvent
Direct Known Subclasses:
PixelmonFaintEvent.Post, PixelmonFaintEvent.Pre

public class PixelmonFaintEvent extends net.minecraftforge.eventbus.api.Event
Fires every time a Pokémon faints Called during battle, or when the Pokémon's health is set to a value less than 0!
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Fired after the poke has fainted
    static class 
    Fired before the fainting occurs Cancelling this will prevent the health going <= 0

    Nested classes/interfaces inherited from class net.minecraftforge.eventbus.api.Event

    net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final net.minecraft.server.level.ServerPlayer
     
    protected final Pokemon
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    PixelmonFaintEvent(net.minecraft.server.level.ServerPlayer player, Pokemon pokemon)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.server.level.ServerPlayer
     
     

    Methods inherited from class net.minecraftforge.eventbus.api.Event

    getListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • player

      protected final net.minecraft.server.level.ServerPlayer player
    • pokemon

      protected final Pokemon pokemon
  • Constructor Details

    • PixelmonFaintEvent

      protected PixelmonFaintEvent(@Nullable net.minecraft.server.level.ServerPlayer player, Pokemon pokemon)
  • Method Details

    • getPlayer

      @Nullable public net.minecraft.server.level.ServerPlayer getPlayer()
    • getPokemon

      public Pokemon getPokemon()