UGantrySettingsProvider
Builds settings pages for one player in code, instead of authoring them as assets.
Use a provider when the pages depend on the player or the machine. Examples are a page of key bindings for whatever the player can rebind, or settings whose values come from functions.
Subclass it in Blueprint or C++ and implement Create Pages. Make each page with New Page, and add settings with the page's Add Setting. Then list the class under Providers, either in Project Settings > Plugins > Gantry Settings or on an experience's Add Settings Pages stage.
Each player's registry makes one provider of each class and calls Create Pages once. It keeps the provider and its pages until the provider is removed. The settings it makes belong to that player alone. In C++, functions you bind to them (BindValue, BindOptions and so on) may therefore capture the player, the registry or the provider.
- Inherits
UObject
Functions
CreatePages
Builds this player's pages.
| Pin | Type | Direction | Description |
|---|---|---|---|
Registry | UGantrySettingsRegistry* | in | The player's registry. |
| Return Value | TArray<UGantrySettingsPage*> | out | The pages, in no particular order (each has its own sort order). |
NewPage
Makes an empty page owned by a player's registry, for settings to be added to.
| Pin | Type | Direction | Description |
|---|---|---|---|
Registry | UGantrySettingsRegistry* | in | The player's registry. |
Title | FText | in | The page's name, for its tab. |
SortOrder = 0 | int32 | in | Where the page goes among the others: lower comes first. |
| Return Value | UGantrySettingsPage* | out | The page, not yet in the registry: return it from Create Pages; null for a null registry. |