MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / IsInGameplay

Method IsInGameplay

engine/Poseidon/Core/Application.cpp:77–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

75}
76
77bool Application::IsInGameplay() const
78{
79 // Active gameplay: a mission world is simulating with its HUD live. GModeIntro
80 // (main menu) also runs a world with a background cutscene and UIEnabled=true, but
81 // that is not player-controlled gameplay. Startup/loading progress can also pump
82 // window events after GWorld exists, before the menu/gameplay state is settled; Alt+F4
83 // must close there too.
84 const bool progressActive = ProgressScript || (GEngine && GetGProgress().Active());
85 return ShouldReportInGameplayForWindowClose(GWorld != nullptr, GWorld && GWorld->GetMode() == GModeIntro,
86 GWorld && GWorld->IsUIEnabled(), progressActive);
87}
88
89Engine* Application::CreateGraphicsEngine(const GraphicsEngineParams& /*params*/)
90{

Callers 2

TriInGameplayFunction · 0.80
HandleEventsMethod · 0.80

Calls 4

ActiveMethod · 0.45
GetModeMethod · 0.45
IsUIEnabledMethod · 0.45

Tested by 1

TriInGameplayFunction · 0.64