2
\$\begingroup\$

I have recently been playing around with the support of the wired XBox 360 controller in Windows development. I am developing in C# in Visual Studio 2012.

I have created 2 projects. The first (Project A) is an XNA project compiled in .Net 4.0. The second (Project B) is a MonoGame 3.0 Windows Open GL project also compiled in .Net 4.0.

My issue is that my wired Xbox 360 controller can only be picked up in Project A - the XNA project. I would really like to continue working with the Monogame type, but have hit a brick wall here.

I have verified that all the requisite libraries (OpenTK, Tao.SDL, SDL) are the exact same files being referenced by both projects. Still, the Monogame project does not pick up the controller.

The exact state of the GamePadState variable is Connected = false.

Any ideas?

Again, same computer, same code for accessing the controller, only difference is XNA vs Monogame.

\$\endgroup\$
3
  • \$\begingroup\$ Monogame uses SDL in order to be able to use a gamepad. Check that SDL.dll is in the project and if not try adding this code to your games constructor: Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonProgramFilesX86), @"MonoGame\v3.0\Assemblies\WindowsGL\SDL.dll"); \$\endgroup\$ Commented Oct 14, 2013 at 20:20
  • \$\begingroup\$ @Potato SDL.dll is being grabbed and placed into the bin folder. The file version is 1.2.14.0 - not sure if anyone else has had problems with that one. Seems to be the latest build. \$\endgroup\$ Commented Oct 14, 2013 at 20:50
  • \$\begingroup\$ I have the same problem. SDL.dll is in the bin ordner here as well, but IsConnected is always false. Have you made any progress yet? \$\endgroup\$
    – JDM
    Commented Oct 23, 2014 at 17:14

1 Answer 1

-1
\$\begingroup\$

I found myself that it is a bug of OpenGL version of Monogame. Just create DirectX version and it should work.

Edit1: Issue has been send to the tracker. https://monogame.codeplex.com/workitem/7812

\$\endgroup\$
2
  • 1
    \$\begingroup\$ This isn't a very good solution to the problem. \$\endgroup\$
    – user1430
    Commented Apr 11, 2014 at 1:39
  • \$\begingroup\$ Well there isn't any fix right now. I've posted issue to the bug-tracker. And there is no need to use OpenGL version of Monogame on windows. \$\endgroup\$
    – Ghandhikus
    Commented Apr 11, 2014 at 12:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .