Something went wrong while trying to load the full version of this site.

Running MW:LL in Wine on GNU/Linux and associated problems

Dravi

Hello!

I managed to finally get MW:LL running and playable in Wine on GNU/Linux

  • wine-7.0
  • Dedicated clean win64 prefix
  • "winetricks dxvk" to get graphics going
  • Installing wine-mono with msi file from https://dl.winehq.org/wine/wine-mono/ for C#-powered launcher: it appears to be impossible to install Microsoft's dotnet48 in x64 prefix via winetricks, install hangs
  • Critically important: copying original "micross.ttf" file to drive_c/windows/Fonts, containing MS Sans Serif font. This file is not available via winetricks! md5sum of needed file is e3a9c893cd405aca729270d3cbc49559.

It appears that some C# stuff hardcodes "MS Sans Serif" as required font. If you skip this, launcher will never run, showing you generic error about something going wrong and dropping helpful yet obscure C# stacktrace into log file in Documents/My Games/Crysis Wars/MWLL/Launcher directory. Stacktrace will be a bit different but similar on Microsoft's .NET or wine-mono.

I figured out how to run game without launcher (with no functioning multiplayer) before managing to get launcher itself running!

  • I used offline installer (MWLL-Installer.exe with MWLL-Installer-1 .. 4.bin) to do initial extraction of files, followed by applying of all the incremental update zip files on top all until current version, 0.15.4
  • Offline installer will also install outdated .NET from Microsoft without asking. During my experimentation, I moved entire Crysis Wars directory to completely different wine prefix with seemingly no ill effects and opted to use wine-mono instead (dotnet48 refuses to install in x64 wine prefix)
  • Game's multiplayer won't work without something odd launcher performed. Game will even ask you to relaunch it specifically via launcher. Once I got launcher working, all it took is pressing "Install" (launcher will just verify install given entire 0.15.4 is already deployed from zip files) and then launching game. I use dx9 mode, 64 bit binary. Launcher will offer to update DirectX, but with dxvk setup you do not need to install it.
  • Once launcher did it's magic, game will function normally, with some caveats (further below) if launched with script like this:
    #!/bin/bash
    export WINEARCH=win64
    export WINEPREFIX=/home/user/.wine_mwll
    cd "/home/user/.wine_mwll/drive_c" && wine "Crysis Wars/Bin64/Crysis.exe" -dx9 -root "C:\users\user\Documents\My Games\Crysis Wars\MWLL\Client" -mod MWLL
  • Hooray? Almost.

Problems I hope to find help for

Solved! My ISP was blocking IRC client access! Make your own computer reject connection properly to prevent game server list freezing you! There's massive problem I experience: whenever I click "INTERNET GAME" button, game goes to server list screen and HANGS for couple of minutes. However, it will successfully load server list once mandatory couple of minutes pass. Once I loaded server list at least once, game apparently is in logged in state, indicated by "ACCOUNT INFO" button in main menu (which is absent upon launch of game even if you did play multiplayer in past).

Logged in state is incredibly important to me. Unless you log in, "connect" console command will not function. Otherwise I'd simply never touch cursed INTERNET GAME server list and just "connect 193.243.189.53:64180" or similar. I was able to confirm no Internet traffic being generated by usage of "connect" command without login via usage of packet sniffer. It merely produces "connection requested to: 193.243.189.53:64180" and "resolved as: 193.243.189.53:64180" while silently cancelling attempt and never producing activity in net_channelstats thing.

INTERNET GAME server list will hang up for couple of minutes every single time you access it. Including during game as you press Esc and try to display that interface again! It does not seem to be caused by login process, as login data exchange ("\lc\1\challenge... - \login\challenge..." TCP chatter) with 138.201.128.96:29900 (aka gs.clanjadewolf.net:29900) is performed only for first time I open server list after game startup. Game hanging up this way will not consume entire CPU core, only some fraction.

When you already on screen showing servers, "UPDATE SERVER LIST" button causes nothing abnormal, only normal server list refresh. It seems to be specifically INTERNET GAME UI opening up triggering freeze-for-good-few-minutes bug. Notably enough, LAN server list is not affected by this nasty bug! Only INTERNET GAME counterpart will freeze game.

I see two ways I could tackle this problem:

  • Fixing INTERNET GAME server list freezing game. I have no expertise to find what's gone wrong with game as I try to load cursed list and would appreciate help here.
  • Avoiding INTERNET GAME button at all costs and triggering login process via some other way. I was not able to find any commands triggering logged in state with ACCOUNT INFO button becoming visible or associated traffic showing up. If you know way to trigger login without tripping INTERNET GAME server list freeze, tell!

Other, somewhat minor in comparison problems:

  • Game will lock up after a while, with probability rising depending on amount of action in game and time it was running. I try to mitigate this by using best performance user.cfg preset linked from wiki and by restarting game before playing round (if I restart right at end of previous round, I do miss some earlygame thanks to server list freeze bug). I am yet to take a look at what exactly stalled process looks like, but I do not expect it to be hitting any hardware limits, be that free RAM or video memory.
  • Solaris Arena will lock me up me extremely quickly, usually as something is blowing up, not necessarily own mech. Screenshot of game: https://u.teknik.io/pWyMm.png (3.7 MiB file). Image shows me blowing up Solitaire B with heat. The only player is me, the only mech ever built is this Solitaire, I barely spent any time on server. Game was freshly restarted. Maybe fixing this will also fix after-a-while crash normally mitigated by restarts between rounds. Crysis.exe will eat entire CPU core but without change to memory usage.
  • Game does not seem to quit cleanly, forcing me to "killall Crysis.exe". It just freezes up should I use quit button or "quit" console command. CPU usage of Crysis.exe will go idle.

Dravi

triggering login process via some other way

I found odd trick that accomplishes that. Hit that cursed INTERNET GAME button, pay close attention to dialog window that says "CONNECTING TO MWLLNETWORK" and hit Esc as soon as it disappears! Time window to Esc is pretty small, but if done right, it will cancel server list thing and will leave you logged in, free to use console's "connect".

Still would love to know console command that logs me in if there's one. Or how to fix issue directly.


haarp

Hey. It's been a long time since I messed with Wine and Crysis. That was before the Community Edition, before the launcher and before our fake Gamespy server. So bear with me.

The launcher is a necessary evil. It handles signing into "Gamespy" (or rather our replacement dummy) for Crysis, among other things. It's not intended to be able to launch Crysis independently, and it won't function properly without the launcher magic, as you've noticed. Your best bet is to get the launcher running.

The delay after clicking Internet Game sounds like DNS. We had to hardcode some domains in the game's binary (such as the defunct server browser chat) to invalid domains. If they actually resolve (usually due to DNS hijacking), the game will try to connect to something and only time out after a few minutes. Monitor DNS traffic while clicking the button. Also see here.

But unless you're using the launcher, you will still be in a non-logged-in state, or in a state where game servers will reject you, or server admins will ban you on sight.

@fire-hound might have some more recent experiences with Wine: https://forum.mechlivinglegends.net/d/161-playing-or-trying-mw-ll-on-linux-via-wine

Fun fact: The Funbocks servers have been running on Wine since the very beginning! They were a very different beast to tame compared to the client.


Dravi

It's not intended to be able to launch Crysis independently

But once launcher did it's work, it is ok to keep launching independently? I did get launcher working (micross.ttf was the key problem), yet it introduces significant delay in game startup.

or in a state where game servers will reject you

I was experiencing 12thVR servers instakicking me upon connection until admin changed something on their side. I wonder if it was this authentication problem or merely ping (I have rather high ping to them).

If they actually resolve

All my DNS servers seem to properly return NXDOMAIN for those .invalid domains. Interestingly enough, game will also try to resolve and reach "www.ea.com". I placed "sake.invalid" and "motd.gsp.invalid" plus that "www.ea.com" into /etc/hosts, redirecting them to localhost, with no change to behavior of game, as I did not like bogus traffic exiting my computer. I gonna poke around and see some more what game will try to reach whenever server list is opened, but I still suspect server list freeze has nothing to do with hijacking.

Fun fact: The Funbocks servers have been running on Wine since the very beginning! They were a very different beast to tame compared to the client.

Are they still up? At first glance running server was not that difficult once I got launcher to create simple default config with map rotation. Running own server is how I managed to get in touch with person who got me in contact with 12thVR server admin!


haarp

138.201.128.96:6667, same box as GameSpy replacement thing. It even has some server running on it, but I was not able to confirm it being actual IRC daemon.

Yes, that is the CJW server that hosts the master services. It also has an IRC bouncer. Ideally, this connection attempt shouldn't happen in the first place. Is there any way you can figure out which domain name resolves to our IP behind the 6667 connection? I can then turn it into an invalid one in the binary.

It's likely your VPN blackholes IRC outright to prevent abuse (spammers and such use them to evade IP bans).

Dravi Are they still up? At first glance running server was not that difficult once I got launcher to create simple default config with map rotation. Running own server is how I managed to get in touch with person who got me in contact with 12thVR server admin!

I don't have the time anymore to maintain the Funbockses. I ended up taking them down, but can restart them if need be. Servers can still be tricky over Wine, especially if you want to go headless. At least the memory leaks in wineserver have been fixed...


Dravi

Holy shit, I found the problem. Hosting company of VPN I am connected to is silently dropping connections to any 6667 TCP port. And apparently game is trying to reach IRC server. What it's even for? I was not even aware of IRC integration being there.

iptables -I OUTPUT 1 -p tcp --dport 6667 -j REJECT fixes freeze!

So, at the end it's not quite DNS hijacking, but similar grade of network shittery.


haarp

But once launcher did it's work, it is ok to keep launching independently? I did get launcher working (micross.ttf was the key problem), yet it introduces significant delay in game startup.

No, it needs to be used on every launch. Otherwise you're using an unauthenticated client, which will lead to server kickage you experienced.

All my DNS servers seem to properly return NXDOMAIN for those .invalid domains. Interestingly enough, game will also try to resolve and reach "www.ea.com". I placed "sake.invalid" and "motd.gsp.invalid" plus that "www.ea.com" into /etc/hosts, redirecting them to localhost, with no change to behavior of game, as I did not like bogus traffic exiting my computer.

NXDOMAIN is fine, if it can't resolve it can't connect to anything. Using localhost is exactly the wrong course of action, as the game will then try to connect, and wait for a timeout.

And apparently game is trying to reach IRC server. What it's even for?

There used to be a server browser chat. It'll be that. However I wonder what IP it tries to connect to in the first place, as it would have to successfully resolve it first. And that shouldn't happen. Can you figure that out for me? Might help others in the future too.


Dravi

No, it needs to be used on every launch.

Oh well.

and wait for a timeout

No need to wait for timeout if it's localhost that instantly rejects connection, properly, unlike ISP of VPN server that is blocking IRC clients. I guess if I wanted to keep it more elegant while not hammering Internet DNS servers with .invalid lookups I would be running own DNS server locally.

However I wonder what IP it tries to connect to in the first place, as it would have to successfully resolve it first.

138.201.128.96:6667, same box as GameSpy replacement thing. It even has some server running on it, but I was not able to confirm it being actual IRC daemon.

I can imagine people with crappy ISPs blocking IRC clients for shoddy "security reasons" running into same freeze bug.


Dravi

Is there any way you can figure out which domain name resolves to our IP behind the 6667 connection?

Only following domains are resolved before game server connection is established (then game does reverse DNS lookup for server you are connected to). Those are not cached and resolved multiple times, that's why I decided to throw all of them into /etc/hosts:

  • gs.clanjadewolf.net (first seen on game startup) - GameSpy replacement server, not sure why IRC thing is there too
  • www.ea.com (first seen on game startup) - completely useless, as it tries to access long-dead URL http://www.ea.com/editorial/crysis/crysis.xml
  • motd.gsp.invalid (first seen on game startup) - useless DNS noise
  • sake.invalid (first seen when opening server list) - useless DNS noise

IRC thing seems to reuse gs.clanjadewolf.net value for some reason, either by copying it or using same variable. Each version of CryNetwork.dll seems to feature 10 copies of gs.clanjadewolf.net. Want me to try messing with hex editor and check which one is responsible for IRC connection?

It's likely your VPN blackholes IRC outright to prevent abuse

Not their job. Network neutrality, anyone? Also I think it's more about C&C server access by malware. Still extremely dumb to block IRC over that. Ironically, I am using that VPN to bypass censorship my home ISP is forced to do by government. Kinda sucks to spot more censorship done with no prior notice.


haarp

If it's using the gs host, there's not much i can do on my end unfortunately. Thanks for checking!

The reason we're running an IRC bouncer on the same machine is mostly for my own convenience :) Or well, it was 10 years ago. Nowadays not so much.

As for the VPN thing: They aren't providers, so technically they don't fall under net neutrality. I do agree tho. On the other hand, blackholing IRC, mail and the like saves them a lot of headache and legal problems.
If you do want a neutral VPN, your best option is to grab yourself a vserver and host it yourself.


Dravi

Are you sure gs was not simply copied to distinct variable? I'll try to mess around with hex editor to see if I can get game still connect to GameSpy box yet throw IRC thing at .invalid domain. IRC bouncer being present or absent would not affect game hanging for users of crappy ISPs.

If you do want a neutral VPN, your best option is to grab yourself a vserver and host it yourself.

Person running that VPN and giving me access is actually renting a server! I think it's reasonable to expect ISP of rented box to not fuck with traffic. But alas, they do, and this person was not aware of such practice.


Dravi

I was able to identify functions of various copies of gs.clanjadewolf.net in Bin64/CryNetwork.dll file! As I suspected, they are different values doing different stuff!

I changed one value at a time, from gs.clanjadewolf.net to xxxxxxxxxxx.invalid, placed entry for replacement value into /etc/hosts with distinct IP and observed what happened with game, from launch to successfully loading server list. "dunno!" entries changed absolutely nothing and thus I have no idea what they are for.

  • 0x1A9158 - responsible for sending "crysiswars" string upon game launch, 27900 UDP
  • 0x1AA238 - dunno!
  • 0x1AA250 - dunno!
  • 0x1AA268 - dunno!
  • 0x1AA5C8 - responsible for loading actual server list, 28910 TCP
  • 0x1AA8F0 - dunno!
  • 0x1AB270 - IRC thing, seems to be GameSpy chat variant of IRC protocol, 6667 TCP
  • 0x1E7F10 - responsible for GameSpy authentication, 29900 TCP
  • 0x1E8060 - dunno!
  • 0x1E8110 - dunno!

IRC thing can be easily redirected to .invalid domain without breaking authentication and server list loading.


haarp

Interesting, thanks. That might be the solution.

btw, if the game still locks up, give the 32 bit version a try. I remember 64 bit being problemati under Wine.