aboutsummaryrefslogtreecommitdiff
path: root/NorthstarDLL/client
diff options
context:
space:
mode:
authorunknown <for.oliver.kirkham@gmail.com>2023-02-11 03:08:43 +0000
committerBobTheBob <for.oliver.kirkham@gmail.com>2023-02-22 22:18:56 +0000
commit07e386b12cb1a92c99cd5e3034cb4f94f28fb3eb (patch)
treee1c05c9bb83b8860daa2dd18f96a76bae6c5bff9 /NorthstarDLL/client
parente1c781f317e1d798eff5d34d87f9b5ffa3e538f0 (diff)
downloadNorthstarLauncher-07e386b12cb1a92c99cd5e3034cb4f94f28fb3eb.tar.gz
NorthstarLauncher-07e386b12cb1a92c99cd5e3034cb4f94f28fb3eb.zip
commit for merge
Diffstat (limited to 'NorthstarDLL/client')
-rw-r--r--NorthstarDLL/client/audio.h2
-rw-r--r--NorthstarDLL/client/clientvideooverrides.cpp10
-rw-r--r--NorthstarDLL/client/modlocalisation.cpp4
3 files changed, 7 insertions, 9 deletions
diff --git a/NorthstarDLL/client/audio.h b/NorthstarDLL/client/audio.h
index 26cda205..915d52ce 100644
--- a/NorthstarDLL/client/audio.h
+++ b/NorthstarDLL/client/audio.h
@@ -1,7 +1,5 @@
#pragma once
-#include <vector>
-#include <filesystem>
#include <regex>
#include <shared_mutex>
diff --git a/NorthstarDLL/client/clientvideooverrides.cpp b/NorthstarDLL/client/clientvideooverrides.cpp
index d8aa2754..d24dfa14 100644
--- a/NorthstarDLL/client/clientvideooverrides.cpp
+++ b/NorthstarDLL/client/clientvideooverrides.cpp
@@ -11,20 +11,20 @@ void*, __fastcall, (const char* path, uint32_t flags))
spdlog::info("BinkOpen {}", filename);
// figure out which mod is handling the bink
- Mod* fileOwner = nullptr;
- for (Mod& mod : g_pModManager->m_LoadedMods)
+ Mod* pFileOwner = nullptr;
+ for (Mod& mod : g_pModManager->GetMods())
{
if (!mod.m_bEnabled)
continue;
if (std::find(mod.BinkVideos.begin(), mod.BinkVideos.end(), filename) != mod.BinkVideos.end())
- fileOwner = &mod;
+ pFileOwner = &mod;
}
- if (fileOwner)
+ if (pFileOwner)
{
// create new path
- fs::path binkPath(fileOwner->m_ModDirectory / "media" / filename);
+ fs::path binkPath(pFileOwner->m_ModDirectory / "media" / filename);
return BinkOpen(binkPath.string().c_str(), flags);
}
else
diff --git a/NorthstarDLL/client/modlocalisation.cpp b/NorthstarDLL/client/modlocalisation.cpp
index 2b73876b..a2387e64 100644
--- a/NorthstarDLL/client/modlocalisation.cpp
+++ b/NorthstarDLL/client/modlocalisation.cpp
@@ -25,7 +25,7 @@ void, __fastcall, (void* pVguiLocalize))
// clang-format on
{
// load all mod localization manually, so we keep track of all files, not just previously loaded ones
- for (Mod mod : g_pModManager->m_LoadedMods)
+ for (Mod& mod : g_pModManager->GetMods())
if (mod.m_bEnabled)
for (std::string& localisationFile : mod.LocalisationFiles)
CLocalize__AddFile(g_pVguiLocalize, localisationFile.c_str(), nullptr, false);
@@ -43,7 +43,7 @@ void, __fastcall, (void* self))
// previously we did this in CLocalize::AddFile, but for some reason it won't properly overwrite localization from
// files loaded previously if done there, very weird but this works so whatever
- for (Mod mod : g_pModManager->m_LoadedMods)
+ for (Mod& mod : g_pModManager->GetMods())
if (mod.m_bEnabled)
for (std::string& localisationFile : mod.LocalisationFiles)
CLocalize__AddFile(g_pVguiLocalize, localisationFile.c_str(), nullptr, false);