PlayerHead

@JvmName(name = "PlayerHeadState339c1e7d20b9_1")
fun UiScope.PlayerHead(source: StateSource<PlayerSkinSource>, scale: PlayerHeadScale, showHat: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null, loadingContent: UiScope.() -> Unit? = null, failureContent: UiScope.() -> Unit? = null)(source)

Source-backed PlayerHead observing source at the next frame cutoff. Sources remain caller-owned; compatible nodes retain editing, focus, and scrolling state. Literal arguments keep their existing contracts. Equal source values do not re-evaluate this component. The complete modifier chain stays on the actual component; the wrapper delegates parent data and owns the sibling key. Keep sources and dedicated editing states outside observed callbacks. Evaluation and input failures follow ordinary runtime cleanup.


fun UiScope.PlayerHead(source: PlayerSkinSource = PlayerSkinSource.CurrentPlayer, scale: PlayerHeadScale, showHat: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null, loadingContent: UiScope.() -> Unit? = null, failureContent: UiScope.() -> Unit? = null)(source)

Emits one square layered player head at a pixel-perfect integer scale.

Pixel sources render immediately. Lookup sources are resolved asynchronously by the active runtime, publish only at a frame boundary, and ignore completions from superseded sources. loadingContent and failureContent each emit zero or one root and are displayed only for their matching state.

Receiver

active owner-thread screen scope.

Parameters

source

immutable pixels or a platform-neutral profile lookup.

scale

positive integer scale mapping every source texel to an equal square of logical pixels.

showHat

whether the outer hat layer is painted after the face.

modifier

active behavior applied to the head.

key

optional stable sibling identity.

loadingContent

optional zero-or-one-root loading presentation.

failureContent

optional zero-or-one-root failure presentation.

Throws

when pixels or state callback cardinality is invalid.

when no runtime screen evaluation is active.


fun UiScope.PlayerHead(source: PlayerSkinSource = PlayerSkinSource.CurrentPlayer, size: Int = 24, showHat: Boolean = true, modifier: Modifier = Modifier.Empty, key: ElementKey<*>? = null, loadingContent: UiScope.() -> Unit? = null, failureContent: UiScope.() -> Unit? = null)(source)

Deprecated

Use the PlayerHeadScale overload for pixel-perfect integer scaling. Arbitrary sizes remain supported here and use bilinear interpolation when size is not divisible by eight.

Emits one square layered player head at an arbitrary logical size.

Sizes divisible by eight retain nearest-neighbor texel scaling. Other sizes use bilinear interpolation within each face or hat region so atlas pixels outside that region cannot bleed into the result. Pixel sources render immediately, while lookup sources and fallback content follow the same lifecycle as the typed-scale overload.

Receiver

active owner-thread screen scope.

Parameters

source

immutable pixels or a platform-neutral profile lookup.

size

positive logical square extent.

showHat

whether the outer hat layer is painted after the face.

modifier

active behavior applied to the head.

key

optional stable sibling identity.

loadingContent

optional zero-or-one-root loading presentation.

failureContent

optional zero-or-one-root failure presentation.

Throws

when pixels, size, state callback cardinality, or a non-divisible size above 1,024 is invalid.

when no runtime screen evaluation is active.