Combat

Combat HUD

Pooled nameplates + eased HP bars + effect chips + cooldown pips over the combat clients. Client-only UI.

Unity package
com.crossplay.combathud
Depends on
statsabilitiesstatuseffectscullingugui
Shape
client-only · no server half

Unity seams you implement 5

The client half's sockets. Bind your implementation in the client context and Crossplay's client calls it — this is where your models, animators, UI and controls plug in.

ICombatHudNameSource unity SPI

The game's display-name vocabulary: Crossplay has no client-side name registry (names are game data — often encoded in the opaque appearance blob), so plates ask the game. Bind an implementation to put real names on plates; absent, plates fall back to the entity id.

  • bool TryGetName(WorldEntityView view, out string name)

    The display name for an entity, or false to fall back to the default.

ICombatHudStyleSource unity SPI

The game's effect presentation vocabulary: an effect id means nothing to the framework, so the default chip is a deterministic id-derived color + the numeric id. Bind an implementation to style chips with the game's own colors and short labels (icons stay the game's job — swap the whole plate presentation via its own HUD if chips aren't enough).

  • bool TryGetEffectStyle(ushort effectId, out Color color, out string label)

    Style for an effect chip, or false to use the deterministic default.

ICombatLogClient unity SPI

Read access to the live combat log, for games that render their own feed instead of (or beside) the built-in view. Bound by CombatLogPresenter; absent if the piece isn't installed.

  • CombatLog Log

    The current log (bounded ring, oldest first) plus its Changed event.

  • event Action<CombatLogEntry> Logged

    Raised for each newly-appended line (the entry), for a push-style feed.

ICombatLogVocabulary unity SPI

The game's combat-log wording. An ability/effect/stat id means nothing to the framework, so the default is a generic "&lt;name&gt; used ability 3" line; bind an implementation to write real sentences ("Aria casts Fireball", "Goblin takes 12 damage"). Return null to SUPPRESS an event (e.g. hide regen ticks). Color comes from the event's CombatLogEventKind via the options — this SPI is text only, keeping presentation out of the game's vocabulary.

  • string Describe(in CombatLogEvent evt)

    The line to log for an event, or null to drop it.

IHudCameraProvider unity SPI

The camera plates project through. Default: the scene's main camera, cached per frame. Games with camera stacks or custom rigs bind their own.

  • Camera Current