Skip to content
标签
Pouvoir
字数
82 字
阅读时间
1 分钟

PouPlaceHolderAPI

PAPI非常像,但是对象变为了存活实体[LivingEntity]

使用

javascript
placeholder(["%example%", entity]);
kotlin
"%example%".placeholder(entity)

拓展

javascript
//@Placeholder(example,示例占位符,Glom_,1.0.0)
function examplePlaceholder(params, entity, def) {
  //code
}
kotlin
object : PouPlaceHolder(key, name, author, version) {
    override fun onPlaceHolderRequest(params: String, entity: LivingEntity, def: String): String? {
        return scriptManager.invoke<String>(script, function, parameters = arrayOf(params, entity, def))
    }
}.register()

贡献者

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

页面历史