Hello there,
I’m a huge fan of the game and was happy to see that it will eventually come to Linux. Then, I couldn’t wait any longer…
I’ve tried to run the game with Wine or PlayOnLinux before, but always ran into some problem or other…
Now though, with Wine 2.4 staging (things seem to work almost flawlessly)! This post is meant to (a) show other users how I went about running Stonehearth, and (b) to document the problems I encounter.
Setting up
Getting a recent Wine version
I’m on a 64bit Linux Mint, which is based on Ubuntu. I followed a post on OMGUbuntu (Wine 2.0.1 Stable Released, Here’s How To Install it on Ubuntu - OMG! Ubuntu!) to get a recent version of Wine. These are the terminal commands I needed:
sudo apt-add-repository 'Index of /wine-builds/ubuntu’
wget https://dl.winehq.org/wine-builds/Release.key && sudo apt-key add Release.key
sudo apt update && sudo apt-get install winehq-staging
Now, when you enter
wine --version
in the terminal, it should show version 2.4 (or, if you read this in the future, something above that).
I then simply downloaded the Stonehearth ZIP, unpacked it into a folder, and started the /Stonehearth.exe with Wine (starting the /x64/Stonehearth.exe has the same result for me).
How’s it running?
The game starts smoothly and without fault for me. I either simply double-click on the Stonehearth.exe or open a terminal in that directory and launch it via
wine stonehearth.exe
The latter method has the benefit of giving me error messages from within Wine. I immediately get an error which I ignore, which is
err:winediag:SECUR32_initNTLMSP ntlm_auth was not found or is outdated. Make sure that ntlm_auth = 3.0.25 is in your path. Usually, you can find it in the winbind package of your distribution.
(I ignore this, because I believe ntlm_auth is needed for authentication with other services, and SH doesn’t need that.
Issue 1: Too many open files
After some time playing, Stonehearth will no longer accept button presses for me. The game runs on, hearthlings build and I can move the camera, but neither clicks nor button presses register. This includes Esc and F5 (to reload the UI). Nothing works.
Accompanying this, Wine complains that there’s too many files open: I somehow feel that Stonehearth opens all kind of LUA files, maybe, and doesn’t close them anymore?
Failed to create thread
fixme:virtual:NtQueryVirtualMemory (process=0xffffffffffffffff,addr=(nil)) Unimplemented information class: MemoryWorkingSetList
wine: Unhandled exception 0xe0000008 in thread 55 at address 0x7b450cba (thread 0055), starting debugger...
err:winediag:FILE_CreateFile Too many open files, ulimit -n probably needs to be increased
On Linux, you can set the number of allowed open files with the command ulimit. To check how many files any process can open, enter „ulimit -n“. For me, it was 1024. If I raise that number before I start Stonehearth, I can play for longer. If I lower it, I can’t play at all. It seems that Stonehearth has a lot of files open.
Issue 2: Assertion failed
Sometimes (I don’t know when exactly) the game crashes with the error „assertion failed“.
After that, any attempt to load a save results in the same crash.
Assertion Failed: c > 0 && c < ReadBufferSize(C:\rb\ihome\root\SH-OB0-BUILD\stonehearth\source\include\protocol.h:142)
However, if I reboot my system, I can then load normally… which is very strange. Some temporary file seems to be the problem, and after the reboot that file is gone. This is all the insight I can offer regarding this.