aboutsummaryrefslogtreecommitdiff
path: root/NorthstarDedicatedTest/modmanager.h
diff options
context:
space:
mode:
authorBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-07-23 02:32:18 +0100
committerBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-07-23 02:32:18 +0100
commit23a1dafcde70822a9899e9aab190f36521c1aedd (patch)
tree58292b4d3abfa22742c9d8e8fcff208c9c6b2475 /NorthstarDedicatedTest/modmanager.h
parent8564c36b49f5f0451be5036371e421a44425b02e (diff)
downloadNorthstarLauncher-23a1dafcde70822a9899e9aab190f36521c1aedd.tar.gz
NorthstarLauncher-23a1dafcde70822a9899e9aab190f36521c1aedd.zip
add basic vpk file replacement
Diffstat (limited to 'NorthstarDedicatedTest/modmanager.h')
-rw-r--r--NorthstarDedicatedTest/modmanager.h25
1 files changed, 15 insertions, 10 deletions
diff --git a/NorthstarDedicatedTest/modmanager.h b/NorthstarDedicatedTest/modmanager.h
index c5ddb09f..60e51308 100644
--- a/NorthstarDedicatedTest/modmanager.h
+++ b/NorthstarDedicatedTest/modmanager.h
@@ -7,7 +7,7 @@ namespace fs = std::filesystem;
const fs::path MOD_FOLDER_PATH = "R2Northstar/mods";
-class ModConVar
+struct ModConVar
{
public:
std::string Name;
@@ -16,7 +16,7 @@ public:
int Flags;
};
-class ModScriptCallback
+struct ModScriptCallback
{
public:
// would've liked to make it possible to hook arbitrary codecallbacks, but couldn't find a function that calls some ui ones
@@ -30,7 +30,7 @@ public:
std::string AfterCallback;
};
-class ModScript
+struct ModScript
{
public:
std::string Path;
@@ -42,6 +42,8 @@ public:
class Mod
{
public:
+ fs::path ModDirectory;
+
// mod.json stuff:
// the mod's name
@@ -74,19 +76,22 @@ public:
Mod(fs::path modPath, char* jsonBuf);
};
+struct ModOverrideFile
+{
+public:
+ Mod* owningMod;
+ fs::path path;
+};
+
class ModManager
{
-private:
- std::vector<Mod*> loadedMods;
+public:
+ std::vector<Mod*> m_loadedMods;
+ std::vector<ModOverrideFile*> m_modFiles;
public:
ModManager();
void LoadMods();
-
- std::vector<Mod*> GetMods();
- std::vector<Mod*> GetClientMods();
- std::vector<std::string> GetModVpks();
- std::vector<std::string> GetModOverridePaths();
};
void InitialiseModManager(HMODULE baseAddress);