Class ItemGenerateEvent

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      HandlerList getHandlers()
      String getId() 获取物品ID
      OfflinePlayer getPlayer() 获取用于解析物品的玩家
      Map<String, String> getCache() 获取节点缓存
      ConfigReader getConfigSection() 获取物品配置(经过了节点解析, 不包含节点配置)
      ConfigurationSection getSections() 获取节点配置
      ItemStack getItemStack() 获取生成的物品
      void setItemStack(@NonNull() ItemStack itemStack) 设置生成的物品
      static HandlerList getHandlerList()
      • Methods inherited from class org.bukkit.event.Event

        getEventName, getHandlers, isAsynchronous
      • Methods inherited from class pers.neige.neigeitems.event.BasicEvent

        call
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ItemGenerateEvent

        ItemGenerateEvent(String id, OfflinePlayer player, ItemStack itemStack, Map<String, String> cache, ConfigReader configSection, ConfigurationSection sections)
        Parameters:
        id - 物品ID
        player - 用于解析物品的玩家
        itemStack - 生成的物品
        cache - 节点缓存
        configSection - 物品配置(经过了节点解析, 不包含节点配置)
        sections - 节点配置
    • Method Detail

      • getPlayer

        @Nullable() OfflinePlayer getPlayer()

        获取用于解析物品的玩家

      • getSections

        @Nullable() ConfigurationSection getSections()

        获取节点配置

      • getItemStack

        @NonNull() ItemStack getItemStack()

        获取生成的物品

      • setItemStack

         void setItemStack(@NonNull() ItemStack itemStack)

        设置生成的物品

        Parameters:
        itemStack - 生成的物品