feat: use local mappings if available
This commit is contained in:
+11
-1
@@ -26,10 +26,20 @@ class Dumper
|
||||
/*
|
||||
* ensure mapping
|
||||
*/
|
||||
string mappingPath = Path.Combine(Path.GetTempPath(), "DeadByDaylight.usmap");
|
||||
string mappingPath;
|
||||
|
||||
string baseDir = AppDomain.CurrentDomain.BaseDirectory;
|
||||
string localMappingPath = Path.GetFullPath(Path.Combine(baseDir, "..", "..", "..", "res", "mappings", "latest-xbox.usmap"));
|
||||
if (File.Exists(localMappingPath))
|
||||
mappingPath = localMappingPath;
|
||||
else
|
||||
{
|
||||
mappingPath = Path.Combine(Path.GetTempPath(), "DeadByDaylight.usmap");
|
||||
bool hasDownloadedMapping = await DownloadMappingFileAsync(Constants.MappingURL, mappingPath);
|
||||
if (!hasDownloadedMapping)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* compression setup
|
||||
|
||||
Reference in New Issue
Block a user