MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / newSaveGame

Method newSaveGame

game/state/savemanager.cpp:183–193  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

181}
182
183bool SaveManager::newSaveGame(const UString &name, const sp<GameState> gameState) const
184{
185 UString path;
186 if (!findFreePath(path, name))
187 {
188 return false;
189 }
190
191 SaveMetadata manifest(name, path, time(nullptr), SaveType::Manual, gameState);
192 return saveGame(manifest, gameState);
193}
194
195bool SaveManager::overrideGame(const SaveMetadata &metadata, const UString &newName,
196 const sp<GameState> gameState) const

Callers 1

tryToSaveGameMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected