Proton: Duck Game (312530)

Created on 28 Aug 2018  Â·  12Comments  Â·  Source: ValveSoftware/Proton

Running the game doesn't do anything.

system information

steam-312530.log

.NET-XNA Game compatibility - Unofficial

All 12 comments

Maybe Proton could include some XNA to FNA magic? https://github.com/FNA-XNA/FNA

This is blocked by C++/CLI incompatibility, so XnaToFna is one possible route, though this game has _multiple_ C++/CLI dependencies aside from XNA, so it would require something like Maik's specialized variant of the tool:

https://github.com/0x0ade/DuckGame-Linux

4.2-3 slightly improves the situation, but not by a lot - Maik's tools will still be really important for this game.

4.2-3 actually tremendously improves the situation short-term, for several players, using protontricks (protontricks 312530 dotnet40 and protontricks 312530 dinput) is enough to get the game running flawlessly.

For me I had to jump through a few hurdles, specifically I had to purge Proton's .NET framework stub implementations first, as well as manually installing libFAudio for wine 4.2's XAudio implementation. After that, it works as smooth as butter :+1:

And that I am extremely grateful for, for Duck Game I have never before been able to simply click the Play button, and have everything Just Workâ„¢ with no glitches or anything.

As of Proton 4.11-2 ~the only hack that is required now is winetricks dinput~, then the game will launch successfully with the -nothreading flag enabled.

For some reason the game's managed DirectInput layer fails to load entirely without the DXSDK dinput.dll, which leads me to believe that the builtin DLL isn't exporting something that the game expects.

A really scary line from WINEDEBUG=+all:

2594502.987:0025:0026:trace:module:load_so_dll loading L"\\??\\Z:\\home\\flibitijibibo\\Games\\SteamLibrary\\steamapps\\common\\Duck Game\\DInput.dll" from so lib "/home/flibitijibibo/.local/share/Steam/SteamApps/common/Proton 4.11/dist/bin/../lib/wine/dinput.dll.so"

So the (very _very_ terribly named) DInput.dll from the game appears to be conflicting with the builtin dinput.dll, causing some really weird load failures to happen, ending with the FileNotFoundException for DInput's assembly.

An even quicker fix than winetricks is just setting dinput to be native-only in winecfg, which is harmless since the game references dinput8 (as does SDL2, if I remember correctly). I dunno if this is necessarily something that can be fixed easily... we may have to shove in some kind of special rule like we do for large-address-aware games. @madewokherd, @aeikum, any insight here? It doesn't seem like a wine-mono thing since this is "mostly" a native DLL, but I feel like Wine would have run into a bug like this ages ago, native or not...

EDIT: Launch option, for reference:

WINEDLLOVERRIDES="dinput=n" %command% -nothreading

now works without any issue if using protontricks 312530 dotnet40 dinput I see only that with joypad after a while the window become minimized and trying to understand if it is kde or an hotkey.

The protontricks method is not working for me on NixOS. Here are my outputs from protontricks 312530 dotnet40 and launching Duck Game from Steam.

My problems might be better discussed with the protontricks nixpkgs maintainer, but in case I'm missing something obvious I figured I'd comment here.

The protontricks method is not working for me on NixOS. Here are my outputs from protontricks 312530 dotnet40 and launching Duck Game from Steam.

My problems might be better discussed with the protontricks nixpkgs maintainer, but in case I'm missing something obvious I figured I'd comment here.

What version of proton were you trying? I noticed it says Wine version 4.0.2 in your log. You should retry with the latest proton version. I had no problems getting into the game with Proton 4.11-8 after running the protontricks line listed above. Granted it should be plug and play, but then we'd have Valve going from game to game.

Honestly Valve should be outsourcing (and open sourcing) the maintenance of games to trusted maintainers and allow the integration of protontricks/winetricks into their tool set.

Imagine if you could create lutris style install scripts and send pull requests to maintainers.

now works without any issue if using protontricks 312530 dotnet40 dinput I see only that with joypad after a while the window become minimized and trying to understand if it is kde or an hotkey.

I can confirm that was a KDe settings that was creating issues. Works flawlessy on Linux with 4 controllers :-)

@betam4x I've revisited this with Proton 5.0-4. I launched the game to get the crash and create the prefix, then ran protontricks. The logs look about the same. Again, it crashed on launch, but then I restarted Steam and tried again. This time, it said "Performing first time setup". After a significant amount of time, the game finally launched, but unfortunately, the duck was stuck moving left on the menu screen. I could only get it to stop by holding down right (d). Closing and relaunching the game gave me the same issue. But it did launch!

I then restarted Steam again, and now the game window opens briefly to a black screen before instantly crashing. Here are those logs. Maybe someone can diff them with logs when the game is working?

Edit: Also, I tried the above launch options (WINEDLLOVERRIDES="dinput=n" %command% -nothreading) but they didn't help. I think the crash has to do with the line in the logs mentioning "fork without exec", but I don't know how to fix that.

The game started working for me for a while on the standard build branch with WINEDLLOVERRIDES="dinput=n" %command% -nothreading, but after the latest big update it no longer works. It crashes immediately with no Proton log from PROTON_LOG=1, but after protontricks 312530 dotnet40 dinput, Duck Game crashes and gives this error in a crash dialog:

Microsoft.Xna.Framework.Graphics.NoSuitableGraphicsDeviceException: Invalid window
  at Microsoft.Xna.Framework.SDL2_FNAPlatform.CreateWindow () [0x000a9] in <2a509bd9153f43e2a56073000f1bcdc4>:0
  at Microsoft.Xna.Framework.Game..ctor () [0x000cd] in <2a509bd9153f43e2a56073000f1bcdc4>:0
  at DuckGame.MonoMain..ctor () [0x0003b] in <6f5c838d2ab84f6bae28e11de2f7f6f3>:0
  at DuckGame.Main..ctor () [0x0002c] in <6f5c838d2ab84f6bae28e11de2f7f6f3>:0
  at DuckGame.Program.DoMain (System.String[] args) [0x00394] in <6f5c838d2ab84f6bae28e11de2f7f6f3>:0
  at DuckGame.Program.Main (System.String[] args) [0x0007d] in <6f5c838d2ab84f6bae28e11de2f7f6f3>:0

Date: 11/13/2020
Version: 1.1.7621.30336
Platform: Windows 10 (Steam Build 5827912)
Online: 0
Mods:
Time Played: 00:00:01 (0)
Special Code:
FIELD FAILED
Level: null
Command Line: -nothreading

The Proton log is huge and I don't know which errors can be ignored but here's some context from that error:

5467.467:0100:0104:trace:loaddll:load_so_dll Loaded L"C:\\windows\\system32\\OPENGL32.DLL" at 0x7a840000: builtin
5467.479:0100:0104:err:wgl:X11DRV_WineGL_InitOpenglInfo  couldn't initialize OpenGL, expect problems
5467.480:0100:0104:fixme:win:RegisterTouchWindow (0x10068 00000003): stub
5467.498:0100:0104:trace:mscoree:mono_assembly_preload_hook_fn "System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
5467.500:0100:0104:trace:loaddll:load_native_dll Loaded L"Z:\\home\\lh\\.local\\share\\Steam\\steamapps\\common\\Proton 5.0\\dist\\share\\wine\\mono\\wine-mono-4.9.4\\lib\\mono\\gac\\System.Configuration\\4.0.0.0__b03f5f7f11d50a3a\\System.Configuration.dll" at 0xe070000: native
5467.500:0100:0104:trace:mscoree:_CorDllMain (0E070000, 1, 00000000)
5467.563:0100:0104:trace:loaddll:load_native_dll Loaded L"Z:\\home\\lh\\.local\\share\\Steam\\steamapps\\common\\Proton 5.0\\dist\\share\\wine\\mono\\wine-mono-4.9.4\\lib\\mono\\gac\\System.Drawing\\4.0.0.0__b03f5f7f11d50a3a\\gdiplus.dll" at 0x6f680000: PE builtin
[00000104:] EXCEPTION handling: Microsoft.Xna.Framework.Graphics.NoSuitableGraphicsDeviceException: Invalid window

couldn't initialize OpenGL, expect problems seems pretty bad. I'm on NixOS which is a bit quirky but someone on Steam had the same issue on Arch. Others in a Duck Game Discord running Ubuntu seem to be doing fine.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Elkasitu picture Elkasitu  Â·  3Comments

shanefagan picture shanefagan  Â·  3Comments

leifmetcalf picture leifmetcalf  Â·  3Comments

shaphanpena1 picture shaphanpena1  Â·  3Comments

ghost picture ghost  Â·  3Comments