Module libr35.descent2e.monster-info.MonsterInformationHelper
Save the current object state
Functions
clean_up_board () | Clean up created figs and health counters |
do_nothing () | Named aptly, this does nothing |
flatten_dice_data (dice) | Flatten the dice data structure into a table of strings |
load_monster_data (name, act, callback) | Load Monster Data |
onLoad (saved_data) | Called when TTS is creating the object |
parse_monster_card_name (card_name) | Parse the monster card in the box on the mat The expected format is "Monster Name (Act I)" or "Monster Name (Act II)" |
reset_dice_indicators () | Reset the Dice Indicators to invisible |
setup_dice_for (target_label, params) | Helper function to setup dice by button label |
setup_lieutenant_dice_indicators () | Setup the Lieutenant dice indicators |
setup_master_dice_indicators () | Setup the master dice indicators |
setup_minion_dice_indicators () | Setup the minion dice indicators |
setup_monster () | Setup the monster based on the card that has been left inside the box |
Functions
- clean_up_board ()
- Clean up created figs and health counters
- do_nothing ()
- Named aptly, this does nothing
- flatten_dice_data (dice)
-
Flatten the dice data structure into a table of strings
Parameters:
- dice
Returns:
-
Table of dice colors, repeated for each count
- load_monster_data (name, act, callback)
-
Load Monster Data This will call the r35 Descent 2e Monster Information API
to get details about the card in the cardbox
Parameters:
- name string Name of the monster (or lieutenant)
- act string|integer The act for the monster (or lieutenant)
- callback
function
WebRequest
callback function
- onLoad (saved_data)
-
Called when TTS is creating the object
Parameters:
- saved_data string The object's persisted state
- parse_monster_card_name (card_name)
-
Parse the monster card in the box on the mat
The expected format is "Monster Name (Act I)" or "Monster Name (Act II)"
Parameters:
- card_name string The name of the card object being parsed
- reset_dice_indicators ()
- Reset the Dice Indicators to invisible
- setup_dice_for (target_label, params)
-
Helper function to setup dice by button label
Parameters:
- target_label string the button label that will be looked up
- params table
See also:
- setup_lieutenant_dice_indicators ()
-
Setup the Lieutenant dice indicators
See also:
- setup_master_dice_indicators ()
-
Setup the master dice indicators
See also:
- setup_minion_dice_indicators ()
-
Setup the minion dice indicators
See also:
- setup_monster ()
- Setup the monster based on the card that has been left inside the box