Skip to content

Token Lighting

Eligarf edited this page Jan 30, 2023 · 3 revisions

Dim/Dark labels don't affect non-hidden visibility in Stealthy!

This applies only to D&D 5e at the moment

There are three phases of work:

  • Detecting the light level on the token itself, which is independant of viewer. Stealthy looks for 'Dim' or 'Dark' status effects on the token and does no light calculations itself - see Token Light Condition for this work. These effects can be renamed if the GM so chooses.
  • Capturing the advantage/disadvantage state of the viewers perception in order to do the right thing when applying disadvantage in dim vision.
    • Stealthy gets these flags on the active rolls, and can generate an extra roll result we can store in our flag so that we have a result for disadvantage should we need it.
    • Don't yet know how to handle pre-existing passive disadvantage on perception inside the visibility test itself, so this edge case will cause those tokens to end up taking the -5 penalty twice.
      • One possibility will be to cache the passive perception state at the start of the perception update for a passive observer by rolling a dummy perception test and looking at the advantage/disadvantage flags in the result.
      • Have to figure out how to add flags to the viewing config that is sent around through the subsequent visibility tests
  • Remapping the dim/dark light level per viewer based on their viewing mode. After the light level is remapped, Hidden objects in Dark get rejected and objects in Dim are tested against using disadvantaged perception.

Dim implies Lightly Obscured status, but I don't want to just switch the language over to that because there are sources of obscuration that have nothing to do with lighting, and I don't want Stealthy incorrectly removing or ignoring those. You are free, of course, to change the label names as you see fit for your game and group requirements; see Localization.

Clone this wiki locally