0x0ade / DuckGame-Linux

Collection of patches to get Duck Game running on Linux using FNA, not Wine. Scroll down for instructions.
MIT License
49 stars 3 forks source link

Controls are all set to ??? and can't be rebinded #3

Open humding3r opened 6 years ago

humding3r commented 6 years ago

https://i.imgur.com/HzTr87j.png : Image of the issue I did everything as described in the instructions, and Duck Game did launch. However, when I tried to rebind my controls to my preferences, all the controls were preset to ???, and when I attempted to change them, it would let me select the control, but it wouldn't let me bind the key.

0x0ade commented 6 years ago

That seems to be the fake DInput controller. Even when the "DInput proxy" is disabled, the game still sees a fake controller. Unfortunately I can't track this down and it's (currently) just cosmetic.

You can switch the binding menu using left / right. Does the game see any other controllers than that? What controllers (if any) are you using?

If you're just using mouse & keyboard input (no controller), can you still access the keyboard binding menu?

jbjjbjjbj commented 6 years ago

The keyboard controls work fine when playing the game and getting to the menu, but rebinding is not possible.

Mte90 commented 5 years ago

Issue confirmed, for me the game is unplayable with joypads... I get this error: [XnaToFnaHelper] [ProxyDInput] ProxyDInput disabled by default - 'export XTF_PROXY_DINPUT=1' to enable

If I execute that command the game crash with this errors:

Setting breakpad minidump AppID = 312530
Steam_SetMinidumpSteamID:  Caching Steam ID:  xxxxxxxx [API loaded no]
[XnaToFnaHelper] [ProxyForms] Creating control DeviceChangeNotifier, globally #1
[XnaToFnaHelper] [ProxyForms] Creating game ProxyForms.GameForm
[XnaToFnaHelper] [ProxyForms] Creating control GameForm, globally #2
IGLDevice: OpenGLDevice
OpenGL Device: Mesa DRI Intel(R) Haswell Mobile 
OpenGL Driver: 3.0 Mesa 19.1.4
OpenGL Vendor: Intel Open Source Technology Center
MojoShader Profile: glsl120
EXT_swap_control_tear unsupported. Fall back to standard VSync.
[XnaToFnaHelper] [ProxyDInput] Initializing ProxyDInput
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
  at System.Collections.Generic.List`1[T].get_Item (System.Int32 index) [0x0000c] in <d0e12f672b88444ab4b6d9b2ecf20142>:0 
  at DuckGame.DInputPad.ConvertDInputState (XnaToFna.ProxyDInput.DInputState state) [0x0000d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.DInputPad.GetState (System.Int32 index) [0x00007] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.AnalogGamePad.Update () [0x0015d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Input.Update () [0x00175] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.MonoMain.RunUpdate (Microsoft.Xna.Framework.GameTime gameTime) [0x0016d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.MonoMain.Update (Microsoft.Xna.Framework.GameTime gameTime) [0x00019] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at Microsoft.Xna.Framework.Game.Tick () [0x000ef] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at Microsoft.Xna.Framework.SDL2_FNAPlatform.RunLoop (Microsoft.Xna.Framework.Game game) [0x005b6] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at Microsoft.Xna.Framework.Game.Run () [0x0002c] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at DuckGame.Program.DoMain (System.String[] args) [0x0022e] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Program.orig_Main (System.String[] args) [0x00036] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Program.Main (System.String[] args) [0x000c0] in <636696e3f4b04115938bc56d0d20ccd6>:0 
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
  at System.Collections.Generic.List`1[T].get_Item (System.Int32 index) [0x0000c] in <d0e12f672b88444ab4b6d9b2ecf20142>:0 
  at DuckGame.DInputPad.ConvertDInputState (XnaToFna.ProxyDInput.DInputState state) [0x0000d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.DInputPad.GetState (System.Int32 index) [0x00007] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.AnalogGamePad.Update () [0x0015d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Input.Update () [0x00175] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.MonoMain.RunUpdate (Microsoft.Xna.Framework.GameTime gameTime) [0x0016d] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.MonoMain.Update (Microsoft.Xna.Framework.GameTime gameTime) [0x00019] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at Microsoft.Xna.Framework.Game.Tick () [0x000ef] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at Microsoft.Xna.Framework.SDL2_FNAPlatform.RunLoop (Microsoft.Xna.Framework.Game game) [0x005b6] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at Microsoft.Xna.Framework.Game.Run () [0x0002c] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0 
  at DuckGame.Program.DoMain (System.String[] args) [0x0022e] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Program.orig_Main (System.String[] args) [0x00036] in <636696e3f4b04115938bc56d0d20ccd6>:0 
  at DuckGame.Program.Main (System.String[] args) [0x000c0] in <636696e3f4b04115938bc56d0d20ccd6>:0 

Date: 08/24/2019
Version: 1.0.6451.27778
Platform: Windows XP 64-Bit Edition
Online: FALSE
Editor: False
Time Played: 00:00:00
Special Code:  
Code: 0
Adapter Resolution: 1280x720
Game Resolution: 1280x720
Fullscreen: False
Device: False
Level: null
Mods: 0 (0 enabled)
Command Line: < -nothreading -nomods >
[ERROR] FATAL UNHANDLED EXCEPTION: System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
  at System.Collections.Generic.List`1[T].get_Item (System.Int32 index) [0x0000c] in <d0e12f672b88444ab4b6d9b2ecf20142>:0
  at DuckGame.DInputPad.ConvertDInputState (XnaToFna.ProxyDInput.DInputState state) [0x0000d] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.DInputPad.GetState (System.Int32 index) [0x00007] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.AnalogGamePad.Update () [0x0015d] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.Input.Update () [0x00175] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.MonoMain.RunUpdate (Microsoft.Xna.Framework.GameTime gameTime) [0x0016d] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.MonoMain.Update (Microsoft.Xna.Framework.GameTime gameTime) [0x00019] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at Microsoft.Xna.Framework.Game.Tick () [0x000ef] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0
  at Microsoft.Xna.Framework.SDL2_FNAPlatform.RunLoop (Microsoft.Xna.Framework.Game game) [0x005b6] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0
  at Microsoft.Xna.Framework.Game.Run () [0x0002c] in <e1b9c0c27fca4c54b2ed338bf2affd2b>:0
  at DuckGame.Program.DoMain (System.String[] args) [0x0022e] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.Program.orig_Main (System.String[] args) [0x00036] in <636696e3f4b04115938bc56d0d20ccd6>:0
  at DuckGame.Program.Main (System.String[] args) [0x000c0] in <636696e3f4b04115938bc56d0d20ccd6>:0
AL lib: (EE) alc_cleanup: 1 device not closed
Mte90 commented 5 years ago

Probably the crash is here because there is no check if this index exists https://github.com/0x0ade/XnaToFna/blob/86af5f8d91cdfac4be1ca84a708dff973de1a6e0/src/Helper/ProxyDInput/DInput.cs#L29

As I can see on linux right now this game is not possible to be played with a controller

torzod commented 4 years ago

I am getting the same issue on keyboard (arch linux). Default controls work fine, but i don't like them very much, so I tried to rebind and nothing's working. You say it's not possible to play with a controller, so is there some way i could play with my keybaord? Thanks.