game_bar_widgets¶
Source: base/tealdef/gui/game_bar/game_bar_widgets.d.tl
Notes
Widgets shown in the game bar: game speed buttons, calendar display and the "Weather and Time" editor, camera and music player buttons, and the info display that mods can extend through GameBarInfoDisplayExtension.
GameBarWidgets¶
record global base/tealdef/gui/game_bar/game_bar_widgets.d.tl:3
global record GameBarWidgets
Load: local game_bar_widgets = ug_require "/gui/game_bar/game_bar_widgets.tl"
Notes
Widgets of the game bar.
Fields
| Name | Type | Description |
|---|---|---|
GameSpeedControl |
Recipe<GameSpeedControlParams> |
Recipe of the game speed buttons. used 1× in the base game |
CalendarDisplay |
Recipe<DateState> |
Recipe that shows the given date with a weather icon in the game bar. used 1× in the base game |
CalendarEditorTool |
ReactToolDefinition<CalendarEditorToolParams> |
Tool with the "Weather and Time" window: weather, time of day and calendar speed, plus date and environment when enabled in CalendarEditorToolParams. used 3× in the base game |
AdvancedCameraControl |
Recipe0 |
Toggle button that shows or hides the camera manager window (cameraManagerWindow). used 1× in the base game |
FreeCameraTool |
Recipe<GameContext> |
Button that pushes the free camera tool (input action selectCameraTool). used 1× in the base game |
MusicPlayerControl |
Recipe<GameContext> |
Tool button that opens the music player (input action selectMusicPlayer). used 1× in the base game |
GameBarInfoDisplay |
Recipe0 |
Horizontal, scrollable area that shows all plugins of GameBarInfoDisplayExtension. used 1× in the base game |
GameBarInfoDisplayExtension |
ExtensionPoint0 |
Extension point for widgets in the game bar info display; the base game adds the earnings and transported displays through it. used 2× in the base game |
Functions
makeDateState() : DateState base/tealdef/gui/game_bar/game_bar_widgets.d.tl:17
Call as game_bar_widgets.makeDateState
Notes
Reads the current game date from the world's GAME_TIME component.
Returns DateState: The current date as DateState.
GameBarWidgets.GameSpeedControlParams¶
record base/tealdef/gui/game_bar/game_bar_widgets.d.tl:4
record GameSpeedControlParams
Notes
Parameters of GameSpeedControl.
Used in the base game: 1 time in 1 file
base/content/gui/gui/game_bar/game_bar_widgets.tl:179
Fields
| Name | Type | Description |
|---|---|---|
gameSpeedHelper |
ReactRefWrapApi0<GameSpeedApi> |
API used to read and set the game speed. |
gameUiProxyRootRef |
ReactRefWrap |
Source node for the IA_GAME_PAUSE_OR_CYCLE_SPEED keybinding hint. |
gameCtx |
GameContext |
Game GUI context. |
GameBarWidgets.DateState¶
record base/tealdef/gui/game_bar/game_bar_widgets.d.tl:11
record DateState
Notes
A calendar date split into year, month and day.
Used in the base game: 6 times in 1 file
base/content/gui/gui/game_bar/game_bar_widgets.tl:258
Fields
| Name | Type | Description |
|---|---|---|
year |
integer |
Year. |
month |
integer |
Month. |
day |
integer |
Day of the month. |
GameBarWidgets.CalendarEditorToolParams¶
record base/tealdef/gui/game_bar/game_bar_widgets.d.tl:19
record CalendarEditorToolParams is ToolReactUtil.IToolParam
Notes
Tool parameters of the "Weather and Time" window (CalendarEditorTool).
Used in the base game: 3 times in 2 files
base/content/gui/gui/game_bar/game_bar.tl:33
base/content/gui/gui/game_bar/game_bar_widgets.tl:768
Fields
| Name | Type | Description |
|---|---|---|
dateEditable |
boolean |
Adds the "Current Date" card to change the date. |
environmentEditable |
boolean |
Adds the "Environment" card. |