Ori and the Blind Forest

Ori and the Blind Forest

Vis statistikk:
BLiTZ 3. juli 2015 kl. 17.39
[Tool] Remap controller buttons on non-XBOX gamepads
Please note that Ori and the Blind Forest: Definitive Edition supports native controller remapping. Use this tool only if you have original, non-Definitive edition.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Info

As many of you know it's almost impossible to play Ori with non-XBOX gamepad: all buttons are messed up and Unity's built-in remapper doesn't work properly (you can't rebind jump button). This tool is intended to fix it.

How it works

The included PowerShell script will replace a part of the Ori's code contained in the Assembly-CSharp.dll file. This new code will query the Unity engine for the remapped buttons, instead of original ones, requested by game.

Technical details

The modfied code is in the MoonInput.GetButton(string buttonName) method in the Assembly-CSharp.dll.

Original:

public static bool GetButton(string buttonName) { return Input.GetButton(buttonName); }

Patched:

public static bool GetButton(string buttonName) { // array of the remapped button's numbers, generated by PS1 script from ini file string[] strArray = new string[] { "1", "2", "0", "3", "4", "5", "8", "9", "10", "11", "6", "7" }; Match match = Regex.Match(buttonName, @"^(Joystick\dButton)([0-9]|1[0-1])$", RegexOptions.Singleline); if (match.Success) { return Input.GetButton(match.Groups[1].Value + strArray[int.Parse(match.Groups[2].Value)]); } return Input.GetButton(buttonName); }

How to apply patch

  • Download JoystickTest application[www.planetpointy.co.uk]
  • Go to https://github.com/beatcracker/Ori-Controller-Remap
  • In the bottom right corner click Download ZIP
  • Unblock ZIP file[blogs.msdn.microsoft.com] before unpacking
  • Unpack downloaded ZIP file
  • Go to the Ori-Controller-Remap-master folder
  • Open Ori_Controller_Remap.ini file in Notepad. This file contains controller button mappings for known controllers (Cyborg Rumble Pad, Logitech Dual Action, etc.) and one for you to edit (Your Controller Name).
  • Run JoystickTest application
  • Punch buttons on your controller, note their numbers in JoystickTest, edit ini file accordingly
  • Replace Your Controller Name with any text you like (your controller name, your pet name, your maiden name - it's all up to you).
  • Save Ori_Controller_Remap.ini file
  • Double-click Ori_Controller_Remap.cmd file, it will launch PowerShell script
  • When asked, select configuration you've edited earlier in the ini file
  • Press any key and wait for script to patch your Ori with new controller mapping

How to remove patch

  • Go to the Ori instalation directory
    • Steam: right-click game in library → Properties → Local files → Browse local files
  • Go to the ori_Data\Managed folder
  • Delete Assembly-CSharp.dll
  • Rename Assembly-CSharp.dll.bak to Assembly-CSharp.dll
— Or —
  • Right-click game in library → Properties → Local files → Verify integrity of game cache

Troubleshooting

Q: I've got a red text message saying: Compiler executable file csc.exe cannot be found.

A: You have to install .Net Framework 3.5. For Windows 7 and higher you can do this via Windows GUI or command line:

Command line
  • Run cmd.exe or PowerShell.exe as Administrator
  • Copy/Paste text below and press Enter:
  • DISM /Online /Enable-Feature /FeatureName:NetFx3 /All

Windows GUI
  • Press Windows Logo + R keys on the keyboard.
  • Type appwiz.cpl in the Run command box and press ENTER.
  • In the Programs and Features window, click on the link Turn Windows features on or off.
  • Check if the .NET Framework 3.5 (includes .NET 2.0 and 3.0) option is available in it.
  • If yes, then enable it and then click on OK.
  • Follow the on-screen instructions to complete the installation and restart the computer, if prompted.

For Windows Vista and below you have to install it from Microsoft website: Microsoft .NET Framework 3.5 Service Pack 1[www.microsoft.com]

Q: Script worked for other buttons, but I stil can't use Triggers on my gamepad

A: I don't know why it happens, but some users reported that this could be fixed by using JoyToKey[joytokey.net].
  • Quote from Steam user Interceptor: Open JoyToKey program and hit the RTrigger button on your controller, it will light up the corresponding line in Joy2Key where you can click this specific button and assign it to Shift on your keyboard. So essentially when you're pressing that button on your controller you're holding the shift button on your keyboard (and thus allowing you to grab/slide)
Q: I've changed input settings in Unity's built-in remapper (held Shift while starting Ori), but now I want to reset it to default. How can I do it? There's no option to reset.

A: Just delete all keys starting with __Input in this registry key: HKEY_CURRENT_USER\Software\Microsoft Studios\Ori And The Blind Forest.

Q: Script can't find my Ori installation (Assembly-CSharp.dll file)

A: Are you running non-Steam version of Ori? Script uses registry keys created by Steam to locate Ori installation folder. If it can't find it, it looks for the required files in the script folder. So you have to copy those files in the script folder:
  • Assembly-CSharp.dll
  • mscorlib.dll
  • System.dll
  • UnityEngine.dll
Those files are located in the X:\Ori_Installation_Directory\ori_Data\Managed\. After the patch, you have to copy and replace Assembly-CSharp.dll file back to ther Ori installation folder. Three other files are required to build the patch code, but not modfied.

Q: Script doesn't work, produces red text and warnings not mentioned above, etc.

A: Run script, right-click window title, select Edit->Select All, press Enter. This will copy all text on screen. Then post it to the Steam Community or GitHub issues[github.com] and I'll try to help you.

Final note

If the tool works for you, please, post your Ori_Controller_Remap.ini file and controller name to the Steam Community or GitHub issues[github.com], so I can update my script with it.
Sist redigert av BLiTZ; 15. juli 2017 kl. 4.17
< >
Viser 4660 av 69 kommentarer
BLiTZ 4. mars 2016 kl. 16.03 
Dark3nss, ๖ۣۜAvensol - Thanks for the ini-files, I've added them to the fix.
Juan B.C 4. mars 2016 kl. 17.04 
Opprinnelig skrevet av BLiTZ:
Dark3nss, ๖ۣۜAvensol - Thanks for the ini-files, I've added them to the fix.

Work for you?
Nice! haha
Whitespliff 7. mars 2016 kl. 13.22 
Tnx, works perfectly.
rc3.808080 8. mars 2016 kl. 9.02 
I use InputMapper and a PS4 controller. It was pretty much plug and play after I downloaded it, just run the program before firing up Steam (or a game). I use my MadCatz Xbox 360 controller a lot too, but I love the PS4 controller.

My next controller tho will probably be the Forza Xbox 1 controller tho, sexy....
Mary 8. mars 2016 kl. 9.23 
I tryed all this and other tutorials out there an nothing worked. I have a ps2 original controller with the blue triangle adapter. Anyone using this was able to make it work?
Juan B.C 8. mars 2016 kl. 16.11 
Opprinnelig skrevet av marycmuller:
I tryed all this and other tutorials out there an nothing worked. I have a ps2 original controller with the blue triangle adapter. Anyone using this was able to make it work?

Try My .ini files. Using a PSOne with the blue triangle adapter.

[PS TO PC CONVERTER]
I don't know if yours is labeled like this but have a try! post back!
bickman 9. mars 2016 kl. 6.10 
太感谢了,我试了好多软件,都解决不了,你这个方法最好,还提供了详细的步骤和技术细节,cool,thanks
bickman 9. mars 2016 kl. 6.51 
except the RT and LT dont work ,I am trying the Joy2key
Mary 10. mars 2016 kl. 17.41 
Opprinnelig skrevet av Dark3nss:
Opprinnelig skrevet av marycmuller:
I tryed all this and other tutorials out there an nothing worked. I have a ps2 original controller with the blue triangle adapter. Anyone using this was able to make it work?

Try My .ini files. Using a PSOne with the blue triangle adapter.

[PS TO PC CONVERTER]
I don't know if yours is labeled like this but have a try! post back!

Im gonna give it a try! Thanks!
Goodums 24. mars 2016 kl. 3.30 
Opprinnelig skrevet av BLiTZ:
Opprinnelig skrevet av Emanate:
After some experimenting, everything works fine but I /did/ still have to use JoyToKey to remap the trigger buttons. Though from what I've seen that's a problem with the game, not the mapping.
Thanks for Ini file, I've updated the fix. Also, there is a whole thread dedicated to triggers issue. For non-XBOX controllers, disabling Nvidia ShadowPlay and removing from devices anything, that can pose as joystick (gaming mice, etc) seems to help.

Thank you for linking the thread, it was able to allow me to correct my trigger problem for now.
I simply had to just take my steam controller configuration and change right trigger to shift and it is working as intended.
Kenshin 17. apr. 2016 kl. 15.26 
Thank you so much for your efforts seems like a nice fix, unfortunately it did't work for me, i get the following error: http://i.imgur.com/qQdJu3B.png?1
BLiTZ 22. apr. 2016 kl. 1.16 
Opprinnelig skrevet av EIG.Kenshin:
Thank you so much for your efforts seems like a nice fix, unfortunately it did't work for me, i get the following error: http://i.imgur.com/qQdJu3B.png?1

You have to install .Net Framework 3.5 (it's not installed by default on Win10):

Opprinnelig skrevet av BLiTZ:
Troubleshooting

Q: I've got a red text message saying: Compiler executable file csc.exe cannot be found.

A: You have to install .Net Framework 3.5. For Windows 7 and higher you can do this via Windows GUI or command line:

Command line
  • Run cmd.exe or PowerShell.exe as Administrator
  • Copy/Paste text below and press Enter:
  • DISM /Online /Enable-Feature /FeatureName:NetFx3 /All

Windows GUI
  • Press Windows Logo + R keys on the keyboard.
  • Type appwiz.cpl in the Run command box and press ENTER.
  • In the Programs and Features window, click on the link Turn Windows features on or off.
  • Check if the .NET Framework 3.5 (includes .NET 2.0 and 3.0) option is available in it.
  • If yes, then enable it and then click on OK.
  • Follow the on-screen instructions to complete the installation and restart the computer, if prompted.

For Windows Vista and below you have to install it from Microsoft website: Microsoft .NET Framework 3.5 Service Pack 1[www.microsoft.com]
Sist redigert av BLiTZ; 22. apr. 2016 kl. 1.17
KCrossX 28. apr. 2016 kl. 23.55 
can you make this to work for DE?

Edit: nvm, dev actually provides a way to remap the controller
Sist redigert av KCrossX; 29. apr. 2016 kl. 2.41
BLiTZ 29. apr. 2016 kl. 15.44 
Opprinnelig skrevet av KCrossX:
can you make this to work for DE?

Edit: nvm, dev actually provides a way to remap the controller
Heh, missed DE being released. Glad they made it right this time.
madione 3. juli 2016 kl. 14.18 
FYI, This file might have BEEN safe, but now the .cmd file also tries to install IDP.ALEXA.51

I'm currently working on actually getting permission back from this file to simply delete the folder it came in. It is getting ugly.

And no, my trigger buttons didn't work either. Going with JoyToKey.
< >
Viser 4660 av 69 kommentarer
Per side: 1530 50

Dato lagt ut: 3. juli 2015 kl. 17.39
Innlegg: 69