News:

Welcome to World of Banished!

Main Menu

Linux?

Started by Pangaea, September 12, 2015, 12:29:55 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Pangaea

Hi guys, long time...

Looks like the developer has buggered off if the lack of updates is any sign to go by, so maybe we won't get a native Linux (and Mac) build. Is it possible to get the game working in Linux?

I have Linux Mint 17.1 Cinnamon, which is based on Ubuntu 14.04. I'm playing some other games through PlayOnLinux, but not sure how to get Banished working there. Might be fun to have another go of it. Any ideas?

A Nonny Moose

#1
I am running Banished on Ubuntu 15.04 with wine-1.7.50.  On my machine it runs very slowly.  I have to run at 10x speed for anything to happen at all, but it is an excellent time waster.

At the moment wine is not properly handling the multiprocessing aspects of the game, and I think that is the reason it is so slow.  I run other stuff (notably SimCity 4 Deluxe) flat out.

So, you have to install the game on your wine prefix.  If you have it from Steam, I cannot help you further because I bought mine from GOG.com and don't have the DRM complications.

After you download it, simply run the installer under the Wine Windows Program Loader.  If you have any mods, you must place them in the banished/windata folder (only the *.pkm files).

If it will help you, here is my script that runs Banished from a console:

#!/bin/bash
date
echo "Start Banished"
env WINEPREFIX="/home/john/.wine" nice -19 wine "C:/GOG Games/Banished/Application.exe" \
&>~/banished.log
wine --version &>>~/banished.log
date

So looking at these lines, there is a lot of house keeping for my benefit in there.  wine is very verbose when run this way, and I send the wine log to the file at my main level banished.log so that I can report any wine problems.  If you have any problems with this script, just ask.

________________________________________________________________

Don't hold your breath waiting for a Linux native version of this program.  It is written with Microsoft Visual Studio and uses .NET 4.0 in part.  It is locked in to Windows.

Programmers that use Microsoft's development products are locked into Windows unless they are very, very careful, and even then may get caught.  It is yet another part of Microsoft's "Big Brother Attitude" that has caused a lot of trouble for many of us over the years.  I knew there would be trouble when Microsoft started certifying programmers on VS.  It just gets worse as the years go on.

I cut my teeth in this business long before Microsoft's Gates was born.  Knowing what I know now, he should have been strangled in his crib.  I grew up writing my own operating system software including device drivers.  What a mess these canned O/S providers have made and they actually get away with charging a licence fee for their trash.
Go not to the oracle, for it will say both yea and nay.

[Gone, but not forgotten. Rest easy, you are no longer banished.]
https://www.haskettfh.com/winterton-john-hensall/

Gordon Dry

Not that I'm able to do programming for real, but I have the right to criticize the developers for using the SDKs - I would like to see native C++ or something like that.

Some years ago, as the first applications in .NET came out, I said "Oh no, another kind of Java SDK crap!"

Do the same application in C++, in Java and using .NET - what size got the main executable and what else has to be linked to and loaded?

Roughly I can say, when C++ is 5 MB .exe, than the .jar is perhaps the same size, but 5x RAM is used and for .NET I would say the .exe is bigger AND 5x RAM is used. If not more.
And the performance? Vice versa, I would say. C++ is 100%, so Java and .NET are 20%  :-\

Pangaea

I'm not as knowledgeable as you guys, particularly A Nonny Moose (such a great and creative name!), but I do have some knowledge about Java, SQL and in particular PHP. The increasingly worse versions of Windows for every new iteration is why I finally made the (hopefully permanent) switch to Linux earlier this year. Happened to watch the "Citizenfour" documentary earlier today, and holy mother of crap. Linux won't be free for crap like that I'm sure, but it should be a fair bit better.

I hope the game will eventually become available natively in Linux, but maybe the issues you speak of is why there hasn't been a blog update for about 4 months. The last one, however, mentioned this:
Quote
I've finally got OpenGL rendering Banished with identical output to both the DX9 and DX11 renderers. I've still got a little bit of work to support the boring parts of a rendering engine, such as handling window resizes, switches to fullscreen, and handling renderer changes at runtime. But all that's platform specific code. What really matters here is I now have a working GL implementation that should (hopefully) seamlessly work on OSX and Linux.

I'll keep trying and hope I manage to get it to work. PlayOnLinux makes these wine things easier, but it's still a nag. I tried before but couldn't get it to work. Maybe I need more components added. It's simply difficult to know what is actually needed, and what will mess things up further.

Btw, that "nice" code increases the priority, right?

Oh, and I don't have Steam. That piece of garbage can burn in an exploding volcano for all I care.

Pangaea

#4
Well smack me down. Just ran the install script for POL and it runs well now. Very early of course, random map, but I don't see any slowdowns. Looks like 1x is at the speed it's supposed to run at. Just used the 2.3.0.7 install from GOG, and that got me the 141103 build. Guess I don't need the other one, as it's just for steam (spit) workshop, at least it looks that way.

Hopefully the small mods I made and the ones from RedKetchup still work, without needing to bother with the 141123 patch/toolkit.

Been any major changes in the gameplay from mods over the last year or so btw? It may be that long since I played it last, or near enough.


e: Looking at the setup in POL/wine, there is a stream of components, though I'm not sure how many of these are actually NEEDED.

-d3dcompiler (many)
-d3dx10 (many)
-d3dx11 (_42 and _43)
-d3dx9 (many)
-gdiplus
-xinput1_1
-xinput1_2
-xinput1_3
-xinput9_1_0

The advantage with Playonlinux is that you can have many different installations of wine, so to speak, as you can create a virtual drive for every game or application, and each can use a different version of wine. The Banished script used the 1.7.28 build, though a later one like 50 may work as well of course.

Paeng

Quote from: Pangaea on September 12, 2015, 05:52:39 PMthe 141103 build. Guess I don't need the other one, as it's just for steam (spit) workshop, at least it looks that way.

Yeah, you can stay clear of that, thankfully...  ::)
[i]Heads are round so thoughts can take a turn[/i]
[color=teal][size=8pt]Editor's Choice [b]here[/b][/size][/color]

A Nonny Moose

That's right.  the nice -19 operator sets the priority to just under real time.

My machine is getting to be ancient in terms of Moore's Conjecture.  I've had it for about five years now, and it was getting a little old when I picked it up.  I'll have to save my nickels for a newer model.  What generally forced me to upgrade is if some component goes out of support.

When I first tried "play on Linux" it was in its infancy, and so it has been do it yourself since.  I am glad to hear that people are having success with it, but I prefer to stay with my custom wine prefixes (I have two: 32-bit, 64-bit).  I rather don't like the idea of having a separate prefix for each app even though I have tons of disk space.  I simply develop a new script, and I have another script that lets me create an icon for any new item I care to add.  Here is an image of my latest desktop and you can see a folder called Wine drops where I keep wine executables.

The (usually hidden) launcher contains some of these icons.
Go not to the oracle, for it will say both yea and nay.

[Gone, but not forgotten. Rest easy, you are no longer banished.]
https://www.haskettfh.com/winterton-john-hensall/

Pangaea

Nice quote ;)

This means you have one virtual drive for everything, right?

I appreciate using different ones will take up more disk space, but it does have the benefit of having different components for different games or applications, and using different wine versions as well. Some of the older games can be a bit wobbly. It works well for my purposes at least, and I find it easier than how I did it before, with wine and winetricks. But then I'm not as solid with Linux yet, so that may be part of it ;)

I listed the components used in case a lack of some of them explained the lack of speed on your end, but if that's down to an old PC instead that won't help of course. I have a better PC now than before, so I'd imagine big cities would flow better. From memory the early game is at the same speed; I haven't noticed a slowdown on 1x. Of course, you may have got used to quick speed, and need 10x, but it didn't sound like that was the case from your post, but rather that the game ran slower than it was supposed to do.

A Nonny Moose

Virtual drive?  wine provides for drives a: through z:, all fake of course along with the appropriate version of the registry.  I am currently using windows 7 decor.

It is easy to switch between the wine prefixes using the mv command.  The basic nuisance is the different layout on the C: drive.  With the 64-bit prefix, the C:\Program Files (x64) entry is used for 32-bit installations.  It means adjusting scripts, so I mainly stay with the 32-bit one unless there is a serious need.

I've been in the computer game so long that trivialities like this don't bother me.

Everyone should use whatever floats their boat and gets the job done.
Go not to the oracle, for it will say both yea and nay.

[Gone, but not forgotten. Rest easy, you are no longer banished.]
https://www.haskettfh.com/winterton-john-hensall/

Pangaea

:(

Looks like it doesn't work well after all. Only played a few years, and the game has now crashed twice in quick succession. In earlier times the game didn't crash until I had thousands of people; now I had less than 20.

A Nonny Moose

Odd.  I don't crash.  The game is not very tolerant of loss of focus, but that usually results in a system hang for me, not a crash.  I don't think I've ever hand the game scrubbed by the O/S.

I've opened a Linux Corner in Off Topic.  Might be a better place for discussion.
Go not to the oracle, for it will say both yea and nay.

[Gone, but not forgotten. Rest easy, you are no longer banished.]
https://www.haskettfh.com/winterton-john-hensall/