Template:Stat Block

From Deez Nuts' Sword Coast Campaign
Revision as of 00:39, 27 June 2026 by Wvaske (talk | contribs) (Create 5e stat block template with inline CSS — no stylesheet dependency)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

5e Stat Block Template

Produces a D&D 5e-style stat block using inline CSS (no stylesheet dependency). Designed for DM-facing NPC and enemy pages.

Parameters

All parameters are optional except `name`.

| Parameter | Description | |-----------|-------------| | `name` | Creature name (default: page name) | | `ac` | Armor Class | | `hp` | Hit Points (e.g. "84 (7d10+21)") | | `ward` | Additional HP pool, e.g. Arcane Ward | | `speed` | Speed | | `str`, `dex`, `con`, `int`, `wis`, `cha` | Ability scores (modifiers auto-calculated) | | `saves` | Saving throw bonuses | | `skills` | Skill bonuses | | `damage_vuln` | Damage vulnerabilities | | `damage_res` | Damage resistances | | `damage_imm` | Damage immunities | | `cond_imm` | Condition immunities | | `senses` | Senses (passive Perception included here) | | `languages` | Languages | | `cr` | Challenge rating | | `traits` | Special traits/features (freeform wikitext) | | `actions` | Actions section | | `bonus_actions` | Bonus actions section | | `reactions` | Reactions section | | `legendary` | Legendary actions section | | `block1`, `block2` | Extra freeform blocks at bottom |

Example

{{Stat Block
| name = Vex Ironjaw
| ac = 20 (plate, shield)
| hp = 84 (7d10+21)
| speed = 25 ft
| str = 18 | dex = 10 | con = 16 | int = 10 | wis = 14 | cha = 8
| saves = STR +7, CON +6
| skills = Athletics +7, Perception +5
| senses = Darkvision 60 ft, passive Perception 15
| actions =
  '''Multiattack.''' Two warhammer attacks.<br>
  '''Warhammer.''' ''Melee Weapon Attack:'' +7 to hit, 5 ft, one target. ''Hit:'' 8 (1d8+4) bludgeoning.
| reactions =
  '''Protection.''' Impose disadvantage on an attack against an ally within 5 ft.
}}

Notes

  • Uses only inline CSS — works without `MediaWiki:Common.css` edits.
  • Modifier signs (+/-) are auto-calculated from ability scores.
  • All sections are optional and will not render if empty.
  • For multi-section stat blocks (like the hit squad page), use `traits` for general features, `actions` for attacks, `reactions` for reactions, and `block1`/`block2` for bespoke sections like "Combat Superiority" or "Spellcasting."
  • The template is compact (max-width 420px) and can sit inline alongside prose.