You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Jason Godesky edited this page Jul 19, 2026
·
1 revision
drawStr is a wrapper around drawGuarded that returns any string.
Parameters
uuid: string
The UUID of the roll table you want to roll on (should begin with RollTable.).
fallback: string
The string to return if the drawn item does not contain a description or name (as requested).
field: 'name' | 'description'
Whether the value should be pulled from the result’s name or description.
Default:description
Examples
import{drawStr}from'@revolutionarygamesco/common-foundryvtt'drawStr('RollTable.1111111111111111','a')// A description pulled from the table, or adrawStr('RollTable.1111111111111111','a','name')// A name pulled from the table, or a