aboutsummaryrefslogtreecommitdiff
path: root/src/subgame.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/subgame.h')
-rw-r--r--src/subgame.h28
1 files changed, 27 insertions, 1 deletions
diff --git a/src/subgame.h b/src/subgame.h
index ba2f235ed..1daeb8b15 100644
--- a/src/subgame.h
+++ b/src/subgame.h
@@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <string>
#include <set>
+#include <vector>
struct SubgameSpec
{
@@ -47,7 +48,32 @@ SubgameSpec findSubgame(const std::string &id);
std::set<std::string> getAvailableGameIds();
-std::string getWorldGameId(const std::string &world_path);
+std::string getWorldGameId(const std::string &world_path,
+ bool can_be_legacy=false);
+
+struct WorldSpec
+{
+ std::string path;
+ std::string name;
+ std::string gameid;
+
+ WorldSpec(
+ const std::string &path_="",
+ const std::string &name_="",
+ const std::string &gameid_=""
+ ):
+ path(path_),
+ name(name_),
+ gameid(gameid_)
+ {}
+
+ bool isValid() const
+ {
+ return (name != "" && path != "" && gameid != "");
+ }
+};
+
+std::vector<WorldSpec> getAvailableWorlds();
#endif