Class ShopEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
com.pixelmonmod.pixelmon.api.events.ShopEvent
Direct Known Subclasses:
ShopEvent.Purchase, ShopEvent.Sell

public abstract class ShopEvent extends net.minecraftforge.eventbus.api.Event
Events fired when someone buys/sells from a ShopFactory.builder() created shop.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Fired when a player buys an item from a shop.
    static class 
    Fired when a player sells an item to a shop.

    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 ShopBuilder
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    ShopEvent(net.minecraft.server.level.ServerPlayer player, ShopBuilder shop)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    @Nullable net.minecraft.core.BlockPos
     
    @Nullable net.minecraft.world.entity.Entity
     
    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
    • shop

      protected final ShopBuilder shop
  • Constructor Details

    • ShopEvent

      protected ShopEvent(net.minecraft.server.level.ServerPlayer player, ShopBuilder shop)
  • Method Details

    • getPlayer

      public net.minecraft.server.level.ServerPlayer getPlayer()
    • getEntity

      @Nullable public @Nullable net.minecraft.world.entity.Entity getEntity()
    • getBlockPos

      @Nullable public @Nullable net.minecraft.core.BlockPos getBlockPos()
    • getShop

      public ShopBuilder getShop()