Hard Light Productions Forums

Hosted Projects - Standalone => Wing Commander Saga => Topic started by: niffiwan on March 27, 2012, 05:45:44 am

Title: WCS:DD in Linux with Wine
Post by: niffiwan on March 27, 2012, 05:45:44 am
Update: The Wine AppDB now has instructions (http://appdb.winehq.org/objectManager.php?sClass=version&iId=25648) that include getting the launcher working.  I'll leave my instructions here for now, but I'd recommend following the AppDB guide instead.



If you're like me and you can't wait for the Linux (or Mac) version to be released, you can try running it with wine.  I've played maybe 25 missions and it's worked fine so far.  Hopefully someone else will find this useful - if you have any feedback, please post below!

I'm assuming that you've already downloaded the windows release of Wing Commander Saga: Darkest Dawn and unzipped it into /some/path.

1) Install Wine
Rather than repeat someone else's work, refer to here for general instructions (http://www.winehq.org/site/docs/wineusr-guide/getting-wine).
Ubuntu users can add this PPA (https://launchpad.net/~ubuntu-wine/+archive/ppa) to get access to a recent version of wine.

2) Prepare the Wine environment
I like to keep all my wine apps separate from each other.  I think it makes it easier to run different apps without conflicts.

Open a terminal and run the following command:
Note - you need to keep this terminal window open to run the rest of the commands below.
Code: [Select]
export WINEPREFIX=~/.wine-wcsdd

You can replace .wine-wcsdd with anything you like - the name does not matter.

3) Install WCS:DD
Run the installer with:
Code: [Select]
wine /some/path/darkest-dawn-setup.exe
/some/path is where-ever you extracted the install files to. 

Just accept all the defaults - if you change the install dir you'll need to update the script I use below (if you want to use the script that is).  The install should also put a link on your desktop, I... umm... deleted it because I like the command line :nervous:, but you may prefer to use the link to run the game rather than mess with scripts like I do...

4) Run the game once
Running the game creates some registry paths - it's easier to do this than type them in by hand:
Code: [Select]
wine $WINEPREFIX/drive_c/Program\ Files/Wing\ Commander\ Saga/wcsaga_sse2.exe
(or use the desktop shortcut)

Create a pilot, and then exit.

5) Update the registry
From your terminal, run regedit and set the following key/values in:
Code: [Select]
HKEY_CURRENT_USER -> Software -> Volition -> WingCommanderSaga
You only really need to set the 1st key/value to get your correct video resolution, but the others don't hurt.

NameTypeValueComment
VideocardFs2openREG_SZOGL -(1680x1050)x32 bitChange 1680x1050 to be your resolution
TextureFilterREG_DWORD1
OGL_AnisotropicFilterREG_SZ4.0Or use 8.0, or 16.0
CurrentJoystickREG_DWORD0

6) Play!
Use the desktop shortcut.  Or if you like scripts:
Code: [Select]
#!/bin/bash
export WINEPREFIX=~/.wine-wcsdd
cd $WINEPREFIX/drive_c/Program\ Files/Wing\ Commander\ Saga
wine ./wcsaga_sse2.exe


7) The Launcher
The whole regedit thing could be skipped if you can get the launcher working.  I couldn't, but I didn't try very hard either.  It seems to be a .NET app, so you may have some luck if you want to install mono - at least, that's what wine suggested  ;)
Title: Re: WCS:DD in Linux with Wine
Post by: Tolwyn on March 27, 2012, 05:51:33 am
Fantastic guide. Much appreciated. Stickied!
Title: Re: WCS:DD in Linux with Wine
Post by: Aginor on March 27, 2012, 06:54:45 am
Great guide, thanks!
Title: Re: WCS:DD in Linux with Wine
Post by: Topgun on March 27, 2012, 05:15:45 pm
why can't you use a svn build of fs2?
Title: Re: WCS:DD in Linux with Wine
Post by: headdie on March 27, 2012, 05:19:36 pm
WCS use a custom branch of FSO, you would need to build into your build all the changes they made into FSO for it to work
Title: Re: WCS:DD in Linux with Wine
Post by: MatthTheGeek on March 27, 2012, 05:23:02 pm
Or you'd need the WCS team to actually build one and distribute it, but that must be too hard for them.

Or they could release their code for us to compile, but code's only for devs.
Title: Re: WCS:DD in Linux with Wine
Post by: Dragon on March 27, 2012, 05:24:44 pm
WCS team promised releasing the code a long time ago, so I hope it'll keep that promise. It'll most likely come out with the SDK.
Title: Re: WCS:DD in Linux with Wine
Post by: Tolwyn on March 27, 2012, 05:30:45 pm
Or you'd need the WCS team to actually build one and distribute it, but that must be too hard for them.

Or they could release their code for us to compile, but code's only for devs.

We appreciate your feedback and input on the matter. Thanks for stopping by.
Title: Re: WCS:DD in Linux with Wine
Post by: Darklord42 on March 28, 2012, 10:32:01 am
Then mac users can use wineskin which makes the whole wine on mac very easy to use.

wineskin.doh123.com (http://wineskin.doh123.com)

The app has a very simple to use GUI that lets you install your game into a finder click-able application wrapper, and then you can use whatever tricks you normally use with wine to get the game running. 

I got it working great for standoff. it does add another (aprox.) 150mb to the file, as each wrapper also includes its own x11 package and wine installation.

a native app would still be better :) Wineskines take a few seconds longer to load up for starters.


[EDIT]  Yup the game works in wineskin upon installation.  Also installation of .NET from winetricks will get the launcher working as well.  Only major hitch is joystick isn't detected.  This is a common wine on MacOSX issue as the wine joystick system isn't near as good as it is on linux.  It's only a miracle that it works with WC Prophecy, Secret OPs, and Standoff so I'm not surprised.  Flight by keyboard is a little rough though with a macbook. ;)



Interesting graphical quirk noticed though. The old Mac OSX bug when ships go through a jump they will show through the other side of the jump before vanishing, is actually there.  This is common on native mac builds of FSO but this the first time I tried to run a windows build via wine and I got the same results.   Doesn't happen in windows..  :confused:

My graphics card is an older Nvidia 8600M
Title: Re: WCS:DD in Linux with Wine
Post by: niffiwan on March 29, 2012, 04:11:33 am
I tried installing .NET2.0 with this:
Code: [Select]
winetricks dotnet20

While this lets the launcher run, it's very slow (maybe 3-5 secs to switch tabs and draw everything), plus text (like your resolution) is nearly 75% hidden by the box it's in.  So unfortunately, close to unusable.  There's probably something else that I could install with winetricks that would improve things, but I'm not much of a wine guru, more just a user :)
Title: Re: WCS:DD in Linux with Wine
Post by: Aginor on March 29, 2012, 04:33:46 am
Wait, you can install .NET with wine now?? When did this happen?
(I just realize I last worked with wine some years ago)

Of course you may want to wait for the Linux version of the game to get everything running smoothly, but I admit it feels pretty cool playing with wine and getting something to work that ain't designed for Linux. :)

Anyway, please continue posting if you find out more, it sure is interesting and the more impatient Linux users will like it. :)
Title: Re: WCS:DD in Linux with Wine
Post by: flecht on March 29, 2012, 05:58:04 am
Linux users can use PlayOnLinux (http://www.playonlinux.com/) for easier Wine management (wineprefix, different Wine versions for different apps and many more).
Title: Re: WCS:DD in Linux with Wine
Post by: Athrun on March 29, 2012, 11:14:07 am
Hi, I'm the current maintainer of WCS:DD in WINE's AppDB. I've just updated the HOWTO, it should solve any previous problem with the launcher.

Since this game is OpenGL it should run at native speed, and shouldn't show differences to a native port in terms of performance.

Please check it at:

http://appdb.winehq.org/objectManager.php?sClass=version&iId=25648 (http://appdb.winehq.org/objectManager.php?sClass=version&iId=25648)

Unlucky we cannot give support to derived projects like Wineskin or PlayOnLinux as they change WINE's code, making us difficult to give support to those projects.

Aside of that feel free to ask for any support there.

-------------------------------------------------------------

PS: God I love this game.

Title: Re: WCS:DD in Linux with Wine
Post by: Darklord42 on March 29, 2012, 06:28:33 pm
Afaik, wineskin isn't suppose to change wine's code, it is just an implementation of wine in a mac appropriated package form.  In my experience, if it works in wine on macosx it will work there too.
Title: Re: WCS:DD in Linux with Wine
Post by: Everglide on April 12, 2012, 02:59:48 am
Tolwyn,

Whats the timeframe on the Mac/Linux launcher?

Your news will save me checking the forums on a daily basis   

 :eek:

Title: Re: WCS:DD in Linux with Wine
Post by: Rear_Admiral_Tarsus on June 18, 2018, 05:51:24 am
Just a heads up, I finished a playthrough of Darkest dawn in Linux native running Knossos. It of course has the knossos launcher, but it worked well.

It has 3 minor bugs:

1- Shelton sliding in autopilot causes audio glitches
2- the portraits are sometimes staticky
3- the landing sequence sometimes shows your ship landing through a wall. You survive though.

They are not showstoppers though, happy native penguin time to all!