{{define "title"}}{{.Mark.Name}} — {{.SiteTitle}}{{end}} {{/* One item, wherever it's sitting. Worn, backpack, and vault all show the same facts; only the panel around them differs. The description and the effect line come from gogobee already resolved — Pete renders them, it does not compute them. "inert" is the honest word for a worn item that wants a bond and hasn't got one: it's on you and doing nothing. */}} {{define "itemrow"}}
  • {{.Name}}{{if .Temper}} +{{.Temper}}{{end}} {{if .Tier}}T{{.Tier}}{{end}}{{if .Value}}{{if .Tier}} · {{end}}{{.Value}}g{{end}}
    {{if or .Slot .SkillSource .Attunement}}
    {{if .Slot}}{{.Slot}}{{end}} {{if .SkillSource}}{{.SkillSource}}{{end}} {{if .Attunement}}{{if .Attuned}}bonded{{else if .Worn}}inert · no bond free{{else}}needs a bond{{end}}{{end}}
    {{end}} {{if .Desc}}

    {{.Desc}}

    {{end}} {{if .Effect}}

    {{.Effect}}

    {{end}} {{if .EquipAction}}
    {{end}}
  • {{end}} {{/* The dungeon map. Laid out server-side (who_map.go) into an x/y node field; this just draws it. Edges first so nodes sit on top of the lines. Nothing here is a player-authored string — node kinds are a fixed vocabulary and ids are zone-prefixed — so the SVG carries no injection surface. */}} {{define "dungeonmap"}} {{range .Edges}}{{if .Lock}}{{.Lock}}{{end}}{{end}} {{range .Nodes}}{{if .Current}}{{end}}{{.Glyph}}{{.Label}}{{if .Current}} — you are here{{end}}{{end}} {{end}} {{define "main"}}

    adventurer

    {{.Mark.Name}}

    Level {{.Mark.Level}} {{.Mark.ClassRace}}

    {{if .Mark.OnRun}}{{.Mark.Where}}{{else}}In town{{if .Mark.Idle}} · {{.Mark.Idle}}{{end}}{{end}}

    {{if .HasDetail}}

    Vitals

    Hit points {{.Detail.HPCurrent}} / {{.Detail.HPMax}}{{if .Detail.TempHP}} +{{.Detail.TempHP}}{{end}}
    Armor class {{.Detail.ArmorClass}}
    {{range .Abilities}}
    {{.Label}}
    {{.Score}}
    {{.ModStr}}
    {{end}}
    {{if .Mark.OnRun}}
    {{if .Detail.Room}}
    Room{{.Detail.Room}}
    {{end}}
    Supplies{{.Detail.Supplies}}
    {{if .Detail.ThreatLevel}}
    Threat{{.Detail.ThreatLevel}}
    {{end}}
    {{end}}

    Gear

    {{if .Detail.Gear}}
      {{range .Detail.Gear}}
    • {{.Slot}} {{.Name}}{{if .Masterwork}} {{end}} T{{.Tier}}{{if .Condition}} · {{.Condition}}%{{end}}
    • {{end}}
    {{else}}

    Traveling light — nothing equipped.

    {{end}}
    {{if .MapView}}

    The map

    {{if .Detail.Room}}Room {{.Detail.Room}}{{end}}
    {{template "dungeonmap" .MapView}}
    entrance boss unexplored locked door
    {{end}} {{else}}

    No detailed sheet on file for this adventurer yet — check back after the next snapshot.

    {{end}} {{if .HasHistory}}

    The record

    {{.Trophies.BossKills}}
    bosses down
    {{.Trophies.ZoneClears}}
    zones cleared
    {{.Trophies.TreasuresFound}}
    treasure{{if ne .Trophies.TreasuresFound 1}}s{{end}}
    {{.Trophies.Deaths}}
    death{{if ne .Trophies.Deaths 1}}s{{end}}
    {{.Trophies.Retreats}}
    walked out
    {{if or .Trophies.BossFirsts .Trophies.ZoneFirsts .Trophies.TreasureFirsts}}

    ★ {{if .Trophies.BossFirsts}}{{.Trophies.BossFirsts}} realm-first boss{{if ne .Trophies.BossFirsts 1}}es{{end}}{{end}}{{if and .Trophies.BossFirsts (or .Trophies.ZoneFirsts .Trophies.TreasureFirsts)}}, {{end}}{{if .Trophies.ZoneFirsts}}{{.Trophies.ZoneFirsts}} first clear{{if ne .Trophies.ZoneFirsts 1}}s{{end}}{{end}}{{if and .Trophies.ZoneFirsts .Trophies.TreasureFirsts}}, {{end}}{{if .Trophies.TreasureFirsts}}{{.Trophies.TreasureFirsts}} first hoard{{if ne .Trophies.TreasureFirsts 1}}s{{end}}{{end}}. Nobody had done it before.

    {{end}}
    {{if .Trophies.Bosses}}

    Bosses fought

      {{range .Trophies.Bosses}}
    • {{.Boss}}{{if .First}} {{end}} ×{{.Kills}}
    • {{end}}
    {{end}} {{if .Trophies.Zones}}

    Ground covered

      {{range .Trophies.Zones}}
    • {{.Zone}}{{if .First}} {{end}}{{if .Region}} {{.Region}}{{end}} ×{{.Clears}}
    • {{end}}
    {{end}}
    {{if .Trophies.Treasures}}

    Treasures found

      {{range .Trophies.Treasures}}
    • 💎 {{.Item}}{{if .First}} {{end}} {{if .Zone}}{{.Zone}}{{end}}
    • {{end}}
    {{end}} {{if .Trophies.Milestones}}

    Milestones

    {{range .Trophies.Milestones}} 🏅 {{.}} {{end}}
    {{end}}

    The trail

      {{range .Timeline}}
    1. {{.Label}} {{.When}}
      {{if .Line}}

      {{.Line}}

      {{end}}
    2. {{end}}
    {{if .MoreHistory}}

    Showing the most recent {{len .Timeline}}. The counts above cover everything.

    {{end}}
    {{end}} {{if .HasSelf}}
    Your adventurer only you can see the panels below

    Home

    House tier{{if .Self.House.Tier}}{{.Self.House.Tier}}{{else}}no house{{end}}
    {{if .Self.House.LoanBalance}}
    Loan balance{{.Self.House.LoanBalance}}
    {{end}} {{if .Self.House.Rate}}
    Rate{{.Self.House.Rate}}
    {{end}} {{if .Self.House.Autopay}}
    Autopayon
    {{end}}

    Pets

    {{if .Self.Pets}}
      {{range .Self.Pets}}
    • {{if .Name}}{{.Name}}{{else}}your {{.Type}}{{end}} {{.Type}} lv {{.Level}}{{if .ArmorTier}} · barding T{{.ArmorTier}}{{end}}
    • {{end}}
    {{else}}

    No pets right now.

    {{end}}
    {{if .Worn}}

    Worn

    {{.BondsUsed}} of 3 bonds in use

      {{range .Worn}}{{template "itemrow" .}}{{end}}

    Backpack

    {{else}}

    Backpack

    {{end}} {{if .Backpack}}
      {{range .Backpack}}{{template "itemrow" .}}{{end}}
    {{else}}

    Backpack's empty.

    {{end}} {{if .VaultRows}}

    Vault

      {{range .VaultRows}}{{template "itemrow" .}}{{end}}
    {{end}}
    {{end}}
    {{end}}