Rogue Legacy Tips

Getting the Xbox 360 controller to work

The steps in here should apply to any controller as long as your (linux) system has a driver for it. I'm using an xbox360 controller and it is recognized out of the box in Ubuntu 12.04.

So what's the problem and how can we solve it? Well, the xbox360 controller is an xinput device but wine has implemented support for dinput. The workaround is to use a wrapper that "translates" xinput to dinput. Enter xbox360ce . Here's what to download and how to use it (at least, what worked for me):

I've downloaded these files:

x360ce_lib32_r766.zip, x360ce.App-2.1.2.191.zip
The first zip contains the libs that actually do the translating and the latter is a program that allows you to configure your gamepad (map buttons, joystick axes, d-pad buttons, etc...

To install the game, you will need to prepare your bottle by installing .NET 4.0 in it. There is a crosstie for that. It would be a good idea to add DirectX: Modern to it which also has a crosstie available. Now you can install this game. The installer should supply XNA 4.0. Once that is done it's time to get dirty.

Unpack the zip files into the directory where the game executable resides. Open the bottle manager and go to the Control Panel tab and launch the Game Controllers configurator. You will see two controller detected. Wait what? Yes. I don't know why. I have disabled one:

(Note: after pressing the disable button, the window will not refresh to reflect the change. Click OK and the open the Controller config utility again. It should look like in the image above)

Using the Run Command button in the bottle manager (make sure the correct bottle is selected) go to the folder where you have unpacked the zips and run x360ce.exe. This will run and prompt you to do some stuff. Do what it tells you. It will try to guess, as best it can the button and joytick axis mappings. It will probably get some right and some wrong. Not a problem. This can be fixed by remapping. Here's the config that works for me:

Once you have checked that everything works right, hit the save button. The program might complain that it found no ini file and will offer to create one. Do so. It might also complain that the ini file does not have the right version. Ignore it.

Hang on, we're still not done. We need one more thing because applications that try to find xinput devices will still not be able to. Notice the xinput1_3.dll file that the program shows in the bottom right corner? We'll add and override in winecfg for it.

So, in the same Control Panel tab launch Wine Configuration and go to the Libraries tab, enter xinput1_3 in the box as shown in the screen shot below and then click the Add button. Set it to native.

Click Apply and then OK and you should be done. Try starting your game. You may see the error about the config file that I talked about earlier. That is good, it means the game will use the xinput1_3.dll that we supplied. Hopefully everything works fine for you.


by Silviu Cojocaru on 2013-09-18 16:57:19
Important Information Tips are provided by the CrossOver Community and Advocates. They are not intended to be used for official CodeWeavers Support. For that, please visit our official support pages.
CodeWeavers or its third-party tools process personal data (e.g. browsing data or IP addresses) and use cookies or other identifiers, which are necessary for its functioning and required to achieve the purposes illustrated in our Privacy Policy. You accept the use of cookies or other identifiers by clicking the Acknowledge button.
Please Wait...
eyJjb3VudHJ5IjoiVVMiLCJsYW5nIjoiZW4iLCJjYXJ0IjowLCJ0enMiOi02LCJjZG4iOiJodHRwczpcL1wvbWVkaWEuY29kZXdlYXZlcnMuY29tXC9wdWJcL2Nyb3Nzb3Zlclwvd2Vic2l0ZSIsImNkbnRzIjoxNzMzNzU5ODAxLCJjc3JmX3Rva2VuIjoiZXhTblpOZzM4M0tzdnZZSCIsImdkcHIiOjB9