Skip to content

属性拓展例子

标签
BuffSystem
字数
54 字
阅读时间
1 分钟

兼容属性插件

Kotlin

kotlin
@AutoRegister("com.skillw.attsystem.api.AttrAPI")
object AttributeSystemHook : AttributeProvider {
    override val key: String = "AttributeSystem"
    override fun addAttribute(entity: LivingEntity, key: String, attributes: List<String>) {
        entity.addAttribute(key,attributes,false)
    }

    override fun removeAttribute(entity: LivingEntity, key: String) {
        entity.removeAttribute(key)
    }
}

贡献者

The avatar of contributor named as Glomzzz Glomzzz
The avatar of contributor named as Glom-c Glom-c

页面历史