HudModelSlots beta
Interface of @v12-engine/client
ts
export interface HudModelSlotsWhat a feature describes for the HUD, a slot each (ui.slot(name)), written by its describer as the HUD updates (HudDescriber: ViewPack.describe, GameView.hud.describe, client.hud.describe). The heroes' view (heroesViewPack) fills hero (the panel of a hero selected alone), heroes (the player's, by their portraits) and shop (the shop open); a game without it computes and draws none of them. A game adds a slot of its own by declaration merging, and a part that reads it:
ts
declare module '@v12-engine/client' {
interface HudModelSlots {
waves: { next: number; in: number } | null
}
}Members
hero
ts
hero: HeroPanelInfo | null;The hero alone selected, for its panel; null where none is
heroes
ts
heroes: HeroPortrait[];The player's heroes, by portrait
shop
ts
shop: ShopInfo | null;The shop that is open, for its window; null where none is