message: Replace stored resources loading with simpler code from production resources
diff: @@ -401,22 +401,13 @@ void MapViewState::readStructures(Xml::XmlElement* element)
  }
  auto storedElement = structure->firstChildElement("storage");
  -
  if (storedElement)
  {
  - StorableResources stored;
  - XmlAttribute* storedAttribute = storedElement->firstAttribute();
  - while (attribute)
  - {
  - if (storedAttribute->name() == constants::SAVE_GAME_RESOURCE_0) { storedAttribute->queryIntValue(stored.resources[0]); }
  - else if (storedAttribute->name() == constants::SAVE_GAME_RESOURCE_1) { storedAttribute->queryIntValue(stored.resources[1]); }
  - else if (storedAttribute->name() == constants::SAVE_GAME_RESOURCE_2) { storedAttribute->queryIntValue(stored.resources[2]); }
  - else if (storedAttribute->name() == constants::SAVE_GAME_RESOURCE_3) { storedAttribute->queryIntValue(stored.resources[3]); }
  -
  - storedAttribute = storedAttribute->next();
  - }
  -
  - st->storage() = stored;
  + auto& stored = st->storage();
  + stored.resources[0] = std::stoi(storedElement->attribute(constants::SAVE_GAME_RESOURCE_0));
  + stored.resources[1] = std::stoi(storedElement->attribute(constants::SAVE_GAME_RESOURCE_1));
  + stored.resources[2] = std::stoi(storedElement->attribute(constants::SAVE_GAME_RESOURCE_2));
  + stored.resources[3] = std::stoi(storedElement->attribute(constants::SAVE_GAME_RESOURCE_3));
  }
  