跳到主要内容

【属性槽位】GermAttributeSlots


GermAttributeSlots简介

GermAttributeSlots 是萌芽引擎的免费附属插件,它支持扩展槽位读取AttributePlusSX-AttributePxRpgOriginAttributeAttributeSystemItemLoreOrigin的物品属性


使用须知

**前置:**GermPlugin, AttributeCompatibleAPI

指令作用备注
/gas查看指令帮助仅OP
/gas reload重载插件仅OP

配置文件

SlotConfig.yml

#填写需要读取物品属性的萌芽拓展槽位的identity
AttributeSlots:
- "germplugin_armor_ring"
- "germplugin_armor_artifacts"
- "germplugin_armor_necklace"

API

  1. GermAttributeSlots(属性槽位插件) GermAttributeSlotAPI.refreshAttributeFromIdentities(Player, List`) 用途:根据 GermSlot 物品刷新玩家的属性源

  2. AttributeCompatibleAPI(属性兼容API) ICompatible 接口方法:

  • addAttributeSource(plugin, entity, slotKey, ItemStack)
  • addAttributeSource(plugin, entity, slotKey, List` lore)
  • removeAttributeSource(plugin, entity, slotKey)
  • refreshAttribute(entity) 用途:统一管理不同属性插件的属性源