You are viewing documentation for v1.1. Switch to current version โ†’

๐ŸŽฎ Gorgeous Game Instance

Short Description

GameInstance subclass that hosts Object Variable data and default trunks for global state.

Long Description

UGorgeousGameInstance extends UGameInstance with an AdditionalGorgeousData map and a serialized trunk of default Object Variables. It also ensures root registry fallback behavior is consistent during startup and world changes.

๐Ÿš€ Features

  • Global Object Variable storage via AdditionalGorgeousData.
  • Serialized default payloads via DefaultObjectVariableTrunk.
  • Root registry fallback handling.

๐Ÿ“š Usage Examples

UGorgeousGameInstance* GI = GetGameInstance<UGorgeousGameInstance>();
TMap<FName, FGorgeousObjectVariableEntry>& Data = GI->AdditionalGorgeousData;

Use the AdditionalGorgeousData map to store global Object Variables that persist across levels.

Init

Initializes the game instance and prepares QoL data structures.

void UGorgeousGameInstance::Init()
{
    Super::Init();
}

Best Practices

  • Store global settings or registries in the game instance map.
  • Keep default trunks in sync with editor-authored Object Variables.

Troubleshooting

  • If root fallback data is missing, ensure the game instance class is active in project settings.