difficulty_react_util¶
Source: base/tealdef/gui/menu/difficulty_react_util.d.tl
Notes
Toggle-button row that applies one of the difficulty presets (Easy, Medium, Hard, Very Hard) to a set of game-mechanic parameters.
DifficultyReactUtil¶
record global base/tealdef/gui/menu/difficulty_react_util.d.tl:3
global record DifficultyReactUtil
Load: local difficulty_react_util = ug_require "/gui/menu/difficulty_react_util.tl"
Notes
Util table of difficulty_react_util.tl; holds the DifficultyPresetToggles recipe.
Fields
| Name | Type | Description |
|---|---|---|
DifficultyPresetToggles |
Recipe<DifficultyPresetTogglesParam> |
Toggle-button group with one button per difficulty (Easy, Medium, Hard, Very Hard) that sets the game-mechanic parameters to that preset. used 1× in the base game |
DifficultyReactUtil.DifficultyPresetTogglesParam¶
record base/tealdef/gui/menu/difficulty_react_util.d.tl:4
record DifficultyPresetTogglesParam
Notes
Parameters of DifficultyReactUtil.DifficultyPresetToggles.
Used in the base game: 1 time in 1 file
base/content/gui/gui/menu/difficulty_react_util.tl:8
Fields
| Name | Type | Description |
|---|---|---|
modParams |
{string : integer} |
Current parameter values (parameter key to selected option index) from which the active difficulty is derived. |
Functions
setModParams({string : integer}) base/tealdef/gui/menu/difficulty_react_util.d.tl:6
Notes
Receives the new parameter table after a difficulty button was clicked.
onHover(boolean) base/tealdef/gui/menu/difficulty_react_util.d.tl:7
Notes
Attention callback of the button group (onAttention); called with true or false when the group gains or loses hover/attention.