mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-02-21 18:40:03 +00:00
use plugins dir for working directory so we can get native dlls correctly
This commit is contained in:
parent
226943cb47
commit
edaf7ff84f
@ -30,16 +30,20 @@ namespace EpicRerouter.ModSide
|
|||||||
Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location)!,
|
Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location)!,
|
||||||
"EpicRerouter.exe"
|
"EpicRerouter.exe"
|
||||||
);
|
);
|
||||||
|
Log($"process path = {processPath}");
|
||||||
var args = new[]
|
var args = new[]
|
||||||
{
|
{
|
||||||
Application.productName,
|
Application.productName,
|
||||||
Application.version,
|
Application.version,
|
||||||
Path.GetDirectoryName(typeof(EpicPlatformManager).Assembly.Location)
|
Path.GetDirectoryName(typeof(EpicPlatformManager).Assembly.Location)
|
||||||
};
|
};
|
||||||
|
Log($"args = {args.Join()}");
|
||||||
|
var workingDirectory = Path.GetFullPath(Path.Combine(args[2], "..", "Plugins", "x86_64"));
|
||||||
|
Log($"working dir = {workingDirectory}");
|
||||||
var process = Process.Start(new ProcessStartInfo
|
var process = Process.Start(new ProcessStartInfo
|
||||||
{
|
{
|
||||||
FileName = processPath,
|
FileName = processPath,
|
||||||
WorkingDirectory = Path.GetDirectoryName(processPath)!,
|
WorkingDirectory = workingDirectory,
|
||||||
Arguments = args.Join(x => $"\"{x}\"", " "),
|
Arguments = args.Join(x => $"\"{x}\"", " "),
|
||||||
UseShellExecute = false
|
UseShellExecute = false
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user