message: Rewrite checkSavegameVersion
diff: #include "Common.h"
  #include "Constants.h"
  #include "StructureManager.h"
  +#include "XmlSerializer.h"
  #include "Things/Structures/Structure.h"
  #include "Things/Structures/Warehouse.h"
  #include <NAS2D/Utility.h>
  -#include <NAS2D/Filesystem.h>
  #include <NAS2D/Xml/XmlDocument.h>
  #include <NAS2D/Xml/XmlElement.h>
  @@ -430,35 +430,20 @@ bool doYesNoMessage(const std::string& title, const std::string msg)
  return yes;
  }
  -
  /**
  * Checks a savegame version.
  *
  * \throws Throws a std::runtime_error if there are any errors with a savegame version, formation or missing root nodes.
  - *
  - * \fixme Find a more efficient way to do this.
  */
  void checkSavegameVersion(const std::string& filename)
  {
  - auto xmlFile = Utility<Filesystem>::get().open(filename);
  + auto xmlDocument = openXmlFile(filename, constants::SAVE_GAME_ROOT_NODE);
  - NAS2D::Xml::XmlDocument doc;
  - doc.parse(xmlFile.raw_bytes());
  - if (doc.error())
  - {
  - throw std::runtime_error("Malformed savegame ('" + filename + "'). Error on Row " + std::to_string(doc.errorRow()) + ", Column " + std::to_string(doc.errorCol()) + ": " + doc.errorDesc());
  - }
  -
  - NAS2D::Xml::XmlElement* root = doc.firstChildElement(constants::SAVE_GAME_ROOT_NODE);
  - if (root == nullptr)
  - {
  - throw std::runtime_error("Root element in '" + filename + "' is not '" + constants::SAVE_GAME_ROOT_NODE + "'.");
  - }
  + auto savegameVersion = xmlDocument.firstChildElement(constants::SAVE_GAME_ROOT_NODE)->attribute("version");
  - std::string sg_version = root->attribute("version");
  - if (sg_version != constants::SAVE_GAME_VERSION)
  + if (savegameVersion != constants::SAVE_GAME_VERSION)
  {
  - throw std::runtime_error("Savegame version mismatch: '" + filename + "'. Expected " + constants::SAVE_GAME_VERSION + ", found " + sg_version + ".");
  + throw std::runtime_error("Savegame version mismatch: '" + filename + "'. Expected " + constants::SAVE_GAME_VERSION + ", found " + savegameVersion + ".");
  }
  }
  