mirror of
https://github.com/wabbajack-tools/wabbajack.git
synced 2024-08-30 18:42:17 +00:00
Fix for absolute path in Steam game files
This commit is contained in:
parent
23fecce38b
commit
6225caabaf
@ -4,6 +4,7 @@
|
|||||||
* Make the CDN downloads multi-threaded
|
* Make the CDN downloads multi-threaded
|
||||||
* Optimize installation of included files
|
* Optimize installation of included files
|
||||||
* Reinstate a broken feature with disabled mods
|
* Reinstate a broken feature with disabled mods
|
||||||
|
* Fix for Absolute Paths in Steam files
|
||||||
|
|
||||||
#### Version - 2.0.4.4 - 5/11/2020
|
#### Version - 2.0.4.4 - 5/11/2020
|
||||||
* BA2s store file names as UTF8 instead of UTF7
|
* BA2s store file names as UTF8 instead of UTF7
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Security;
|
using System.Security;
|
||||||
using Microsoft.Win32;
|
using Microsoft.Win32;
|
||||||
@ -155,9 +156,21 @@ namespace Wabbajack.Common.StoreHandlers
|
|||||||
if (!l.ContainsCaseInsensitive("\"installdir\""))
|
if (!l.ContainsCaseInsensitive("\"installdir\""))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
var path = new RelativePath("common").Combine(GetVdfValue(l)).RelativeTo(u);
|
var value = GetVdfValue(l);
|
||||||
if (path.Exists)
|
AbsolutePath absPath;
|
||||||
game.Path = path;
|
|
||||||
|
if (Path.IsPathRooted(value))
|
||||||
|
{
|
||||||
|
absPath = (AbsolutePath)value;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
absPath = new RelativePath("common").Combine(GetVdfValue(l)).RelativeTo(u);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (absPath.Exists)
|
||||||
|
game.Path = absPath;
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!gotID || !game.Path.IsDirectory) return;
|
if (!gotID || !game.Path.IsDirectory) return;
|
||||||
|
Loading…
Reference in New Issue
Block a user