HeadTargetValues

每个玩家、布局实例和元素独立缓存 Kether 头像目标;读取从不等待脚本。 Caches Kether head targets per viewer/layout instance/element without waiting for a script.

目标或变量改变时立即隐藏旧头像;同一元素最多一个脚本在途。背包标题也能读取已完成的目标。 A source/variable change hides the old head immediately. Each slot runs at most one script; inventory titles can read completed targets too.

Types

Link copied to clipboard
sealed class Value

Functions

Link copied to clipboard
fun clear()

重载时丢弃结果及所有在途回调。 / Drops cached results and invalidates in-flight callbacks on reload.

Link copied to clipboard
fun clearContext(viewer: UUID, context: String)
Link copied to clipboard
fun onQuit(event: PlayerQuitEvent)
Link copied to clipboard
fun openContext(viewer: UUID, context: String)

释放短期布局实例的脚本状态。 / Releases script state belonging to a transient layout instance.

Link copied to clipboard
fun peek(player: Player, layout: String, element: String, source: HeadTarget, variables: Map<String, String>, context: String = "default"): HeadTargetValues.Value

同步返回缓存/加载状态;必要的脚本执行与结果归一化回到主线程。 / Returns immediately; script execution and normalization run on the server thread.