UGauntletTestController

Base class for games to implement test controllers that use the Gauntlet native framework.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Gauntlet

Header

/Engine/Plugins/Experimental/Gauntlet/Source/Gauntlet/Public/GauntletTestController.h

Include

#include "GauntletTestController.h"

Syntax

[UCLASS](Programming/UnrealArchitecture/Reference/Classes#classdeclaration)()
class UGauntletTestController : public UObject

Remarks

Base class for games to implement test controllers that use the Gauntlet native framework. This is a very thin class that is created automatically based on command line params (-gauntlet=MyControllerName) and provides easily overridden functions that represent state changes and ticking

In essence your derived class should implement logic that starts and monitors a test, then calls EndTest(Result) when the desired criteria are met (or not!)

Constructors

Name Description

Public function

UGauntletTestController

(
    const FObjectInitializer& ObjectIn...
)

Default constructur

Destructors

Name Description

Public function Virtual

~UGauntletTestController()

Functions

Name Description

Protected function Static

void

 

EndTest

(
    int32 ExitCode
)

Called to end testing and exit the app with provided code, static to avoid test instance state/lifetime dependency

Protected function Const

FString

 

GetCurrentMap()

Return the name of the current persistent map

Protected function Const

FName

 

GetCurrentState()

Returns the current state applied to Gauntlet

Public function Const

APlayerContr...

 

GetFirstPlayerController()

Helper function that returns the first player controller in the world (may be null depending on when called).

Protected function

FGauntletMod...

 

GetGauntlet()

Returns the gauntlet module running this test

Protected function Const

double

 

GetTimeInCurrentState()

Return the time since OnStateChange was called with the current state

Public function Const

UWorld *

 

GetWorld()

Return the current world

Protected function

void

 

MarkHeartbeatActive

(
    const FString& OptionalStatusMessa...
)

Marks the next heartbeat as active and immediately forces a heartbeat with the given status message if one is specified.

Public function Virtual

void

 

OnInit()

Called when the controller is first initialized

Public function Virtual

void

 

OnPostMapChange

(
    UWorld* World
)

Called after a map change.

Public function Virtual

void

 

OnPreMapChange()

Called prior to a map change

Public function Virtual

void

 

OnStateChange

(
    FName OldState,
    FName NewState
)

Called when a state change is applied to the module.

Public function Virtual

void

 

OnTick

(
    float TimeDelta
)

Called periodically to let the controller check and control state

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss