Odd wine runner problem with SWG:Legends

OK so a friend who is looking to convert over full time to linux was curious if this (last one on his hit list) title worked. I got it working just fine via the command line. Telling Lutris how is not working out.

So the trick here is that it comes bundled with a java launcher. And the launcher must be preloaded thru javaw.exe. So here is my shell script that I made to do this all via the system wine:

cd "/home/andrew/Games/wine/swg-legends/drive_c/Program Files (x86)/StarWarsGalaxies"

wine ./lib/jre/bin/javaw.exe -Dprism.order=j2d -Dsun.java2d.d3d=false -jar "/home/andrew/Games/wine/swg-legends/drive_c/Program Files (x86)/StarWarsGalaxies/SWGLegendsLauncher.exe"

My failed attempts had the command all in quotes, not in quotes, using everything past javaw.exe as a parameter on the parameter line… Nada.

Any ideas gang?


rename SWGLegendsLauncher.exe to SWGLegendsLauncher.jar and use the host java install - don’t run via wine - just to test

use the same switches though -Dprism.order=j2d -Dsun.java2d.d3d=false -jar

For all we know the “launcher” is just a gloryfied updater and proxy.

I did a copy, rather than a rename. But, no dice.

andrew@schotty-tower-wired:> cd ~/Games/wine/swg-legends/drive_c/Program\ Files\ (x86)/StarWarsGalaxies/
andrew@schotty-tower-wired:> cp SWGLegendsLauncher.exe SWGLegendsLauncher.jar
andrew@schotty-tower-wired:> java -Dprism.order=j2d -Dsun.java2d.d3d=false -jar SWGLegendsLauncher.jar
Error: Could not find or load main class launcher.Main

I’m going to assume you are using oracle java and not OpenJDK/etc

You’ll have to make sure that JavaFX is also part of your oracle install - not all AUR’s/debs/rpm’s/etc have JavaFX included.

Manifest-Version: 1.0
Implementation-Title: Project8_Legends
X-COMMENT: Main-Class will be added automatically by build
Implementation-Version: 1.0
Permissions: sandbox
Codebase: *
JavaFX-Version: 8.0
Class-Path: lib/ini4j-0.5.4.jar lib/jackson-all-1.9.0.jar lib/jfoenix.
 jar lib/jsoup-1.11.2.jar
Created-By: JavaFX Packager
Implementation-Vendor: MPHI14
Main-Class: launcher.Main

Actually it is OpenJDK:

andrew@schotty-tower-wired:~> java --version
openjdk 11.0.3 2019-04-16
OpenJDK Runtime Environment (build 11.0.3+7-suse-1.1-x8664)
OpenJDK 64-Bit Server VM (build 11.0.3+7-suse-1.1-x8664, mixed mode)

Well there is your problem.
If you look at the included packaged java with the “launcher” its Java 8 u161.
And its oracle’s java - not OpenJDK.

Not everything can run with OpenJDK so its best to use oracle’s java - especially in this case.

Typically dev’s that use Windows use oracle’s jdk - not OpenJDK and that sometimes creates issues when using OpenJDK unless the dev really knows what they are doing.

In short;
Install https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
Windows dev’s always use Oracle JDK - and usually don’t code/adapt for OpenJDK - yes there are different code methods between the two.


My problem is figuring out how to format what Lutris wants. The game is a windows game. Not java. The launcher is java. If I use my script to automate things, it works perfect, just not in Lutris. The only problem involving java is the lutris wine runner not getting told correctly how to fire up the game.


not sure if this is still relevant for you. I bet you have figured it out by now. There are two ways to run the launcher:

-By running javaw.exe shipped with the launcher through wine (as you have figured out)
-By running it with native java(1). There is no need to rename the exe file since java -jar does work against exe files. Also, this does not need the additional parameters (-Dprism.order=j2d and -Dsun.java2d.d3d=false) since they are related to a wine bug. java -jar SWGLegendsLauncher.exe is sufficient.

While currently you can’t launch the game through the launcher if running with native java(2), it does allow for updating the game. Updates are not that frequent, I’d say less than once in a month. So I only start the launcher when updates arrive. The rest of the time, I just use wine to start SwgClient_r.exe directly.

Perhaps if explained properly this is viable for your friend.


(1) I have only tried this with Oracle JRE.
(2) Elour was working on invoking wine to run swgclient_r.exe when linux is detected so this may change in the future.

1 Like