aboutsummaryrefslogtreecommitdiff
path: root/src/headless
diff options
context:
space:
mode:
author ClarkeCode <clarke.john.robert@gmail.com>2023-06-14 05:41:28 +0200
committer ClarkeCode <clarke.john.robert@gmail.com>2023-06-18 07:04:24 +0200
commit741cfe452156f7c6365d1a66b6228e15ef660bf6 (patch)
tree893e5b7b299eff272ec186bdaebc8d91e5ee0bd5 /src/headless
parent5433008d163e7e85cd7ee668e769c649e318f491 (diff)
Rough draft of compiling headless simulation
Diffstat (limited to 'src/headless')
-rw-r--r--src/headless/main.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/headless/main.cpp b/src/headless/main.cpp
new file mode 100644
index 0000000..70a57a9
--- /dev/null
+++ b/src/headless/main.cpp
@@ -0,0 +1,22 @@
+#ifdef OPENVIC_HEADLESS_SIM
+#include <iostream>
+#include <string>
+#include "openvic/Simulation.hpp"
+#include "openvic/dataloader/Dataloader.hpp"
+
+
+int main() {
+ std::cout << "HEADLESS SIMULATION" << std::endl;
+
+
+ std::string vic2FolderLocation = "";
+ if (vic2FolderLocation.length() <= 0) {
+ std::cout << "Path to Victoria 2 folder not specified. Manually specify location: ";
+ std::cin >> vic2FolderLocation;
+ }
+ std::filesystem::path path(vic2FolderLocation);
+
+ OpenVic::Simulation sim;
+ std::cout << (OpenVic::Dataloader::loadDir(path, sim) ? "Dataloader suceeded" : "Dataloader failed") << std::endl;
+}
+#endif \ No newline at end of file