Skip to content

Health Points

Your Players HP can be tracked using the healthpoints widget. This widget requires a state_key be provided so that the plugin can save the character's state within the plugins state file.

State Key Requirement

Each state_key defined in any component needs to be unique as they are all stored within the same key value store internally.

Features

  • Customize 'Hit Points' label
  • Death save tracking
  • Supports temporary HP
  • Supports Reset Events - See Event System for more details. By default it is configured for long-rest.

Image

Rendered Example

Example

yaml
```healthpoints
state_key: din_health
health: 24
hitdice:
  dice: d6
  value: 4
```

TIP

This health key supports dynamic content. This allows you to read your HP from frontmatter.

yaml
```healthpoints
state_key: din_health
health: '{{ frontmatter.hp }}'
hitdice:
  dice: d6
  value: 4
```

Configuration

PropertyTypeDefaultDescription
state_keyStringRequiredUnique identifier for state storage
healthNumberRequiredMaximum health points
labelString"Hit Points"Custom label for the component
hitdiceObjectnullHit dice configuration
death_savesBooleantrueWhether to show death saves
reset_onString/Array/Object"long-rest"Events that reset health

Reset Configuration

The reset_on property supports the same formats as consumables:

Simple String: Complete reset on the specified event

yaml
reset_on: long-rest

Array of Strings: Complete reset on any of the specified events

yaml
reset_on: ["short-rest", "long-rest"]

Array of Objects: Fine-grained control (currently health always resets completely)

yaml
reset_on:
  - event: long-rest  # Complete reset

Hit Dice Object

PropertyTypeDescription
diceStringDice type (e.g., "d6", "d8", "d10")
valueNumberNumber of hit dice available