1
Fork 0
mirror of https://github.com/redstrate/Astra.git synced 2025-04-20 11:47:46 +00:00

Fix unencrypted game args not working when Dalamud is enabled

This commit is contained in:
Joshua Goins 2022-01-27 11:02:57 -05:00
parent 02beef81ce
commit a88f7305d0

View file

@ -183,8 +183,19 @@ void LauncherCore::launchGame(const ProfileSettings& profile, const LoginAuth au
arguments.append(earg); arguments.append(earg);
launchExecutable(profile, gameProcess, arguments); launchExecutable(profile, gameProcess, arguments);
} else { } else {
if(profile.enableDalamud) {
// nativelauncher requires arg[3] to be the arguments, put inside of a quoted string. if this is encrypted, that's easy but this is not
// TODO: combine with code above (they do the same thing lol)
QString finalArg;
for(auto arg : gameArgs) { for(auto arg : gameArgs) {
arguments.push_back(QString(" %1=%2").arg(arg.key, arg.value)); finalArg.append(QString(" %1=%2").arg(arg.key, arg.value));
}
arguments.append(finalArg);
} else {
for(auto arg : gameArgs) {
arguments.append(QString("%1=%2").arg(arg.key, arg.value));
}
} }
launchExecutable(profile, gameProcess, arguments); launchExecutable(profile, gameProcess, arguments);