classinternalinternalSource
@API(status = INTERNAL)
public final class HeadlessWatcher

Watches the log of a headless game until it reached the main menu (or crashed), then stops it

Methods

public static HeadlessWatcher forLaunch(LaunchConfiguration launchConfig, boolean logsNoMarkers)
Parameters
launchConfigLaunchConfiguration
logsNoMarkersbooleanTrue for versions before 1.6, they get the LWJGL window marker
Returns
HeadlessWatcher
public int watch(Process process) throws InterruptedException
Waits until the game logs one of the headless markers, then stops it
Parameters
processProcess
Returns
int0 if a marker was reached without the game crashing, 124 on timeout, otherwise a non-zero exit code
Throws
InterruptedException