fix: try to fix blocking game running when launcher visibility was set to close after game started.
This commit is contained in:
@@ -323,6 +323,9 @@ public class DefaultLauncher extends Launcher {
|
|||||||
Process process;
|
Process process;
|
||||||
try {
|
try {
|
||||||
ProcessBuilder builder = new ProcessBuilder(rawCommandLine).directory(runDirectory);
|
ProcessBuilder builder = new ProcessBuilder(rawCommandLine).directory(runDirectory);
|
||||||
|
if (listener == null) {
|
||||||
|
builder.inheritIO();
|
||||||
|
}
|
||||||
String appdata = options.getGameDir().getAbsoluteFile().getParent();
|
String appdata = options.getGameDir().getAbsoluteFile().getParent();
|
||||||
if (appdata != null) builder.environment().put("APPDATA", appdata);
|
if (appdata != null) builder.environment().put("APPDATA", appdata);
|
||||||
process = builder.start();
|
process = builder.start();
|
||||||
|
|||||||
Reference in New Issue
Block a user