VisualU 1.2.1
Plugin for Unreal Engine 5 that brings core functionality for a widget-based visual novel game
 
Loading...
Searching...
No Matches
UVisualVersioningSubsystem Class Reference

Allows for altering scenes in nodes. More...

#include <VisualVersioningSubsystem.h>

Inheritance diagram for UVisualVersioningSubsystem:

Classes

struct  FScenarioId
 

Public Member Functions

void AlterDataTable (const UDataTable *DataTable, const FName &SceneName, const FVisualScenarioInfo &Version)
 Alters scene in the data table by provided version.
 
template<typename T = FVisualScenarioInfo, typename... V>
void AlterDataTable (const UDataTable *DataTable, const FName &SceneName, V T::*... Members, const V &... Values)
 Template version.
 
template<typename T = FVisualScenarioInfo, typename... V>
void AlterDataTable (FScenario *Scene, V T::*... Members, const V &... Values)
 Template version.
 
void Checkout (FScenario *const Scene) const
 Switches scene to an older version.
 
void CheckoutAll (UDataTable *const DataTable) const
 Switches all scenes in the data table to an older version.
 
virtual void SerializeSubsystem_Experimental (FArchive &Ar)
 Not ready for production code.
 
virtual void Deinitialize () override
 Discards all versions bringing scenes to original state.
 

Private Member Functions

FScenarioGetSceneChecked (const UDataTable *DataTable, const FName &SceneName) const
 Will trigger assertion for invalid data table or name.
 
FScenarioGetSceneChecked (const FScenarioId &Id) const
 Will trigger assertion for invalid scenario id.
 

Private Attributes

TMultiMap< FScenarioId, FVisualScenarioInfoVersions
 Map of scenes to all versions of their information.
 

Detailed Description

Allows for altering scenes in nodes.

All versions are applied and discared at runtime.

Member Function Documentation

◆ AlterDataTable() [1/3]

void UVisualVersioningSubsystem::AlterDataTable ( const UDataTable * DataTable,
const FName & SceneName,
const FVisualScenarioInfo & Version )

Alters scene in the data table by provided version.

Parameters
DataTabledata table that contains desired scene
SceneNamerow name of the desired scene
Versionaltered scene
Returns
result of requesting node
See also
UVisualUBlueprintStatics::Choose()

◆ AlterDataTable() [2/3]

template<typename T = FVisualScenarioInfo, typename... V>
void UVisualVersioningSubsystem::AlterDataTable ( const UDataTable * DataTable,
const FName & SceneName,
V T::*... Members,
const V &... Values )
inline

◆ AlterDataTable() [3/3]

template<typename T = FVisualScenarioInfo, typename... V>
void UVisualVersioningSubsystem::AlterDataTable ( FScenario * Scene,
V T::*... Members,
const V &... Values )
inline

◆ Checkout()

void UVisualVersioningSubsystem::Checkout ( FScenario *const Scene) const

Switches scene to an older version.

Has no effect for scene not altered by this subsystem.

Parameters
Scenescene to revert back to the previous version

◆ CheckoutAll()

void UVisualVersioningSubsystem::CheckoutAll ( UDataTable *const DataTable) const

Switches all scenes in the data table to an older version.

Has no effect for scenes not altered by this subsystem.

Parameters
DataTablenode which scenes will be reverted to previous version

◆ Deinitialize()

void UVisualVersioningSubsystem::Deinitialize ( )
overridevirtual

Discards all versions bringing scenes to original state.

Called when local player is destroyed.

◆ GetSceneChecked() [1/2]

FScenario * UVisualVersioningSubsystem::GetSceneChecked ( const FScenarioId & Id) const
private

Will trigger assertion for invalid scenario id.

Parameters
Ididentity of requested scene
Returns
identified scene

◆ GetSceneChecked() [2/2]

FScenario * UVisualVersioningSubsystem::GetSceneChecked ( const UDataTable * DataTable,
const FName & SceneName ) const
private

Will trigger assertion for invalid data table or name.

Parameters
DataTabledata table that contains desired scene
SceneNamerow name of desired scene
Returns
scene from data table at given location

◆ SerializeSubsystem_Experimental()

void UVisualVersioningSubsystem::SerializeSubsystem_Experimental ( FArchive & Ar)
virtual

Not ready for production code.

Parameters
Ararchive to serialize this subsystem

The documentation for this class was generated from the following files: