mirror of
https://github.com/wabbajack-tools/wabbajack.git
synced 2024-08-30 18:42:17 +00:00
Merge branch 'GameFinder-Upgrade' into pre-release
# Conflicts: # CHANGELOG.md
This commit is contained in:
@ -1,6 +1,11 @@
|
||||
### Changelog
|
||||
|
||||
#### Version - TBD
|
||||
* Updated GameFinder to 4.1.0
|
||||
* Fixes Wabbajack not Launching on some systems
|
||||
* Added the GameFinder module for EA Desktop
|
||||
* Only `Dragon Age: Origins` & `Dragon Age: Inquisition` supported for now.
|
||||
* For other games we still need to collect the right store IDs
|
||||
* Fixed Final Fantasy 7: Remake Intergrade meta data
|
||||
|
||||
#### Version - 3.4.1.0 - 12/21/2023
|
||||
|
@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices.JavaScript;
|
||||
using Wabbajack.Paths;
|
||||
|
||||
namespace Wabbajack.DTOs;
|
||||
@ -29,6 +30,8 @@ public class GameMetaData
|
||||
// EAPlay games may have @subscription appended to the file name
|
||||
public string[] OriginIDs { get; set; } = Array.Empty<string>();
|
||||
|
||||
public string[] EADesktopIDs { get; set; } = Array.Empty<string>();
|
||||
|
||||
public string[] EpicGameStoreIDs { get; internal init; } = Array.Empty<string>();
|
||||
|
||||
// to get BethNet IDs: check the registry
|
||||
|
@ -357,6 +357,22 @@ public static class GameRegistry
|
||||
MO2Name = "Dragon Age: Origins",
|
||||
SteamIDs = new[] {47810},
|
||||
OriginIDs = new[] {"DR:169789300", "DR:208591800"},
|
||||
EADesktopIDs = new [] // Possibly Wrong
|
||||
{
|
||||
"9df89a8e-b201-4507-8a8d-bd6799fedb18",
|
||||
"Origin.SFT.50.0000078",
|
||||
"Origin.SFT.50.0000078",
|
||||
"Origin.SFT.50.0000078",
|
||||
"Origin.SFT.50.0000085",
|
||||
"Origin.SFT.50.0000086",
|
||||
"Origin.SFT.50.0000087",
|
||||
"Origin.SFT.50.0000088",
|
||||
"Origin.SFT.50.0000089",
|
||||
"Origin.SFT.50.0000090",
|
||||
"Origin.SFT.50.0000091",
|
||||
"Origin.SFT.50.0000097",
|
||||
"Origin.SFT.50.0000098"
|
||||
},
|
||||
GOGIDs = new long[] {1949616134},
|
||||
RequiredFiles = new[]
|
||||
{
|
||||
@ -374,6 +390,22 @@ public static class GameRegistry
|
||||
MO2Name = "Dragon Age 2", // Probably wrong
|
||||
SteamIDs = new[] {1238040},
|
||||
OriginIDs = new[] {"OFB-EAST:59474", "DR:201797000"},
|
||||
EADesktopIDs = new [] // Possibly Wrong
|
||||
{
|
||||
"Origin.SFT.50.0000073",
|
||||
"Origin.SFT.50.0000255",
|
||||
"Origin.SFT.50.0000256",
|
||||
"Origin.SFT.50.0000257",
|
||||
"Origin.SFT.50.0000288",
|
||||
"Origin.SFT.50.0000310",
|
||||
"Origin.SFT.50.0000311",
|
||||
"Origin.SFT.50.0000356",
|
||||
"Origin.SFT.50.0000385",
|
||||
"Origin.SFT.50.0000429",
|
||||
"Origin.SFT.50.0000449",
|
||||
"Origin.SFT.50.0000452",
|
||||
"Origin.SFT.50.0000453"
|
||||
},
|
||||
RequiredFiles = new[]
|
||||
{
|
||||
@"bin_ship\DragonAge2.exe".ToRelativePath()
|
||||
|
@ -1,6 +1,8 @@
|
||||
using System.Runtime.InteropServices;
|
||||
using GameFinder.Common;
|
||||
using GameFinder.RegistryUtils;
|
||||
using GameFinder.StoreHandlers.EADesktop;
|
||||
using GameFinder.StoreHandlers.EADesktop.Crypto.Windows;
|
||||
using GameFinder.StoreHandlers.EGS;
|
||||
using GameFinder.StoreHandlers.GOG;
|
||||
using GameFinder.StoreHandlers.Origin;
|
||||
@ -20,12 +22,14 @@ public class GameLocator : IGameLocator
|
||||
private readonly GOGHandler? _gog;
|
||||
private readonly EGSHandler? _egs;
|
||||
private readonly OriginHandler? _origin;
|
||||
private readonly EADesktopHandler? _eaDesktop;
|
||||
|
||||
private readonly Dictionary<AppId, AbsolutePath> _steamGames = new();
|
||||
private readonly Dictionary<GOGGameId, AbsolutePath> _gogGames = new();
|
||||
private readonly Dictionary<EGSGameId, AbsolutePath> _egsGames = new();
|
||||
private readonly Dictionary<OriginGameId, AbsolutePath> _originGames = new();
|
||||
|
||||
private readonly Dictionary<EADesktopGameId, AbsolutePath> _eaDesktopGames = new();
|
||||
|
||||
private readonly Dictionary<Game, AbsolutePath> _locationCache;
|
||||
private readonly ILogger<GameLocator> _logger;
|
||||
|
||||
@ -42,6 +46,7 @@ public class GameLocator : IGameLocator
|
||||
_gog = new GOGHandler(windowsRegistry, fileSystem);
|
||||
_egs = new EGSHandler(windowsRegistry, fileSystem);
|
||||
_origin = new OriginHandler(fileSystem);
|
||||
_eaDesktop = new EADesktopHandler(fileSystem, new HardwareInfoProvider());
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -90,6 +95,14 @@ public class GameLocator : IGameLocator
|
||||
{
|
||||
_logger.LogError(e, "While finding games installed with Origin");
|
||||
}
|
||||
try
|
||||
{
|
||||
FindStoreGames(_eaDesktop, _eaDesktopGames, game => (AbsolutePath)game.BaseInstallPath.GetFullPath());
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
_logger.LogError(e, "While finding games installed with EADesktop");
|
||||
}
|
||||
}
|
||||
|
||||
private void FindStoreGames<TGame, TId>(
|
||||
@ -189,6 +202,13 @@ public class GameLocator : IGameLocator
|
||||
path = found;
|
||||
return true;
|
||||
}
|
||||
|
||||
foreach (var id in metaData.EADesktopIDs)
|
||||
{
|
||||
if (!_eaDesktopGames.TryGetValue(EADesktopGameId.From(id), out var found)) continue;
|
||||
path = found;
|
||||
return true;
|
||||
}
|
||||
|
||||
path = default;
|
||||
return false;
|
||||
|
@ -18,10 +18,11 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="GameFinder.StoreHandlers.EGS" Version="4.0.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.GOG" Version="4.0.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.Origin" Version="4.0.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.Steam" Version="4.0.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.EADesktop" Version="4.1.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.EGS" Version="4.1.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.GOG" Version="4.1.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.Origin" Version="4.1.0" />
|
||||
<PackageReference Include="GameFinder.StoreHandlers.Steam" Version="4.1.0" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
Reference in New Issue
Block a user