Changeset View
Changeset View
Standalone View
Standalone View
source/ps/GameSetup/GameSetup.cpp
Show First 20 Lines • Show All 712 Lines • ▼ Show 20 Lines | catch (PSERROR_Game_World_MapLoadFailed& e) | ||||
// Call script function to do the actual work | // Call script function to do the actual work | ||||
// (delete game data, switch GUI page, show error, etc.) | // (delete game data, switch GUI page, show error, etc.) | ||||
CancelLoad(CStr(e.what()).FromUTF8()); | CancelLoad(CStr(e.what()).FromUTF8()); | ||||
} | } | ||||
} | } | ||||
void InitNonVisual(const CmdLineArgs& args) | void InitNonVisual(const CmdLineArgs& args) | ||||
{ | { | ||||
g_GUI = new CGUIManager(); | |||||
vladislavbelov: Why do we need GUI in non visual mode? | |||||
bbAuthorUnsubmitted Done Inline ActionsThe gamesettings are currently in the gui. One might argue that we should move those elsewhere. bb: The gamesettings are currently in the gui. One might argue that we should move those elsewhere. | |||||
vladislavbelovUnsubmitted Not Done Inline ActionsYou'd need to add if (CRenderer::IsInitialised()) for everything that's used for GUI and might be called. That doesn't seem right. vladislavbelov: You'd need to add `if (CRenderer::IsInitialised())` for everything that's used for GUI and… | |||||
wraitiiUnsubmitted Not Done Inline Actions
Having a headless GUI doesn't seem completely bonkers, to be honest. wraitii: > You'd need to add `if (CRenderer::IsInitialised())` for everything that's used for GUI and… | |||||
wraitiiUnsubmitted Not Done Inline Actions
I debated this originally, and ended up not doing it, but yes, this seems to me like a good argument for moving them to their own subfolder. wraitii: > The gamesettings are currently in the gui. One might argue that we should move those… | |||||
Autostart(args); | Autostart(args); | ||||
} | } | ||||
/** | /** | ||||
* Temporarily loads a scenario map and retrieves the "ScriptSettings" JSON | * Temporarily loads a scenario map and retrieves the "ScriptSettings" JSON | ||||
* data from it. | * data from it. | ||||
* The scenario map format is used for scenario and skirmish map types (random | * The scenario map format is used for scenario and skirmish map types (random | ||||
* games do not use a "map" (format) but a small JavaScript program which | * games do not use a "map" (format) but a small JavaScript program which | ||||
▲ Show 20 Lines • Show All 460 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator
Why do we need GUI in non visual mode?