* Load the game using a (reader) filter. * @param reader The filter to read the savegame from. * @return Return the result of the action. #SL_OK or #SL_REINIT ("unload" the game) */
| 3236 | * @return Return the result of the action. #SL_OK or #SL_REINIT ("unload" the game) |
| 3237 | */ |
| 3238 | SaveOrLoadResult LoadWithFilter(std::shared_ptr<LoadFilter> reader) |
| 3239 | { |
| 3240 | try { |
| 3241 | _sl.action = SLA_LOAD; |
| 3242 | return DoLoad(std::move(reader), false); |
| 3243 | } catch (...) { |
| 3244 | ClearSaveLoadState(); |
| 3245 | return SL_REINIT; |
| 3246 | } |
| 3247 | } |
| 3248 | |
| 3249 | /** |
| 3250 | * Main Save or Load function where the high-level saveload functions are |
no test coverage detected