FINAL FANTASY VIII

FINAL FANTASY VIII

Ikke nok vurderinger
Controller Mapping with Autohotkey & Sensible Button Inputs in Game
Af dean.dip
A guide to using Autohotkey and the provided script for mapping an entire Xbox 360 controller (and some other controllers too) to work with FFVIII And a guide to have sensible button inputs for the 360 controller (instead of seeing B1-10) listed in the game.

This makes the Dpad, Triggers, and both Thumbsticks work with the game!

The provided script can be configured to suit other games as well!
   
Pris
Føj til foretrukne
Gjort til foretrukken
Fjern som foretrukken
Get Autohotkey
First we want to get the Autohotkey software that will map the controller buttons and other inputs to keyboard buttons.

Get v1.1 installer (current release is v1.1.16.05 as of creating this guide) of Autohotkey from http://ahkscript.org/download/
v1.0 should work too, but v2.0 (currently in alpha) won't work without changes to the syntax of my script.

After installing we're ready to start creating and/or using scripts. Scripts are saved as .ahk
The Script(s)
Now open notepad and copy and paste the text from
http://pastie.org/pastes/9943449/text
-(right thumbstick as arrow keys and configurable)
or
http://pastie.org/pastes/9943454/text
-(this one has right thumbstick as mouse and right thumbstick button press as mouse click)
into notepad and save it as a .ahk file. You may name it something like Controller.ahk

If you want to use a button icon mod (MCINDUS has one here) to have a better representation of buttons in game or if you don't care about seeing B1-10 in game for button names, then here are scripts that only cover controller inputs not used by the game (Dpad, Triggers, Right Thumbstick):
http://pastie.org/pastes/9943222/text
-(right thumbstick as arrow keys and configurable)
http://pastie.org/pastes/9943224/text
-(right thumbstick as mouse and right thumbstick button press as mouse click)

If you don't want to use one of the 2 scripts above, you may skip the rest of this section, If you do want to, you may want to have FFVIII's keyboard settings set to default to match the script if you want to leave the trigger assignments untouched. (Left Trigger is assigned to Rotate Left and Right Trigger is assigned to Rotate Right/Trigger)

Controller configuration is easier changed in game if using a button icon mod.

This is how I prefer to have my controller settings
(using MCINDUS' FF8 Controller Button Icon mod - normal version not HID):


This is how it looks outside the game in Controller Settings if you happen to need this:



Going this route, you can skip to the Running the Script section at the end of the guide.
Looking at the Script
Unless you trust my controller mappings are all well and good, right click on the newly created file and select edit script.

Take a look at the button assignments, trigger assignments and maybe the Dpad & Thumbsticks. I have put comments in the script to help find and configure the parts of the controller easier.
(a ; makes the rest of the line in a script not act as code, making it a comment)

I have the buttons assigned to keys with letters that resemble the 360 controller button letters with the exception of LB and RB on the controller being mapped to 1 & 2 respectively and the back/select button being mapped to k. I also have the left trigger set to use F1 (for speed boost) You may wish to change that to l (lowercase L) instead.

The dpad and left and right thumbsticks are mapped to the arrow keys (except the second script has the right thumbstick as mouse), but I made them configurable in case one may want special assignments for them. Just an idea of what you can do, you could make the right thumbstick control the volume (with first script).

One may find how to enter advanced inputs here: http://www.autohotkey.com/docs/commands/Send.htm

A note about the triggers on a 360 controller: Pressing both triggers at the same time will cause them to act as if neither is being pressed! Both trigger inputs are tied together in a way that causes that unfortunately. There is a way to have them be read separately using Xinput[msdn.microsoft.com], but it's difficult to use (for me at least).

If any changes to the script were made, save the script.
Changes to Game Settings
This section is for getting the game to recognize the controller as keyboard inputs, and not have the game show B1-B10 for button inputs, but instead show keyboard buttons for inputs.

Now open the game and click on settings, then click on the Keyboard tab. Alternatively, if no changes were made to the script, you could skip to the next section.

Change the inputs to how they are mapped in the script. This is how I have mine:
After hitting ok to save the changes, we'll want to change a file to disable controller input from being read by the game.

In a file explorer go to:
%USERPROFILE%\My Documents\Square Enix\FINAL FANTASY VIII Steam
Edit the file called ff8input.cfg with something other than notepad, like wordpad or notepad++ if you have it. (notepad doesn't recognize the returns, making it hard to read)

Change the numbers below the Joystick section to all be 0s so that it looks like this
Joystick 1. "Select" 0 2. "Exit" 0 3. "Misc" 0 4. "Menu" 0 5. "Toggle" 0 6. "Trigger" 0 7. "RotLt" 0 8. "RotRt" 0 9. "Start" 0 10. "Select" 0 11. "Up" 0 12. "Down" 0 13. "Left" 0 14. "Right" 0
Save the file and now the game won't try to use its own settings for the controller nor show controller buttons (B1-10) in game. Also, the controller can be used to skip the opening screens of the game instead of having to use the keyboard to skip them.

Keep from opening the controller tab in the game settings, but it should still be ok to open the keyboard tab. If you open the controller tab, you may have to resave the 0s to the ff8input.cfg file.
Slightly Quicker Alternative
If you did the section above or changed button assignments in the script, skip this section.

In a file explorer go to:
%USERPROFILE%\My Documents\Square Enix\FINAL FANTASY VIII Steam

Edit the file called ff8input.cfg
Copy the text below
Keyboard 1. "Select" 21 2. "Exit" 30 3. "Misc" 45 4. "Menu" 48 5. "Toggle" 38 6. "Trigger" 19 7. "RotLt" 2 8. "RotRt" 3 9. "Start" 31 10. "Select" 37 11. "Up" 200 12. "Down" 208 13. "Left" 203 14. "Right" 205 Joystick 1. "Select" 0 2. "Exit" 0 3. "Misc" 0 4. "Menu" 0 5. "Toggle" 0 6. "Trigger" 0 7. "RotLt" 0 8. "RotRt" 0 9. "Start" 0 10. "Select" 0 11. "Up" 0 12. "Down" 0 13. "Left" 0 14. "Right" 0
Select all the text in ff8input.cfg (ctrl+a) and paste the above so that it replaces all the old text; then save the file.

Now the game has its keyboard mappings set and won't try to use its own settings for the controller nor show controller buttons (B1-10) in game. Also, the controller can be used to skip the opening screens of the game instead of having to use the keyboard to skip them.

Keep from opening the controller tab in the game settings, but it should still be ok to open the keyboard tab. If you open the controller tab, you may have to resave the joystick section to the ff8input.cfg file.
Running the Script
To get the script to run, all you have to do is double click on the .ahk file you saved.

While it is running, the script will show in the system tray like this:




When you wish to end the script from running, right click the system tray icon and exit it like this:





Now you may enjoy Final Fantasy VIII with the ultimate controller experience.
18 kommentarer
Treeck 23. juni 2018 kl. 18:11 
Okay, I see. I didn't know that. I'll try 1.1 version one instead of v2. I'll report back later when I have time to check it out.
dean.dip  [ophavsmand] 23. juni 2018 kl. 17:59 
@Treeckcold57 First, I have to ask if you're using the 1.1 verson of Autohotkey because v2 definitely won't work.

I don't have FFVIII installed currently so I can't quickly see if there's something obviously wrong with my script or instructions due to an update or something

And I see that Pastie.org is down for good. I just assumed it was only gonna be temporarily down.
Treeck 23. juni 2018 kl. 9:08 
Hi, I tried this method, but I was unable to play with my Xbox 360 S controller. What did I do wrong exactly? I created a new script and copied from this http://pasted.co/7ed92e17 . I launched FF8 steam and then ran script in the background. This script actually didn't responded at all, and yes. I already edited ff8inputcfg to set zero for all the joystick buttons. Can you help me to fix this? Thanks!
dean.dip  [ophavsmand] 8. mar. 2017 kl. 17:49 
While pastie.org is down, you can get the scripts here: FFVIII Controller [pasted.co] and FFVIII Controller with Mouse [pasted.co]
Tltlvilus 3. mar. 2017 kl. 22:42 
pastie.org broken
dean.dip  [ophavsmand] 27. mar. 2016 kl. 23:58 
@Moogy Regarding still having the B2, B3, etc. showing, make sure you see the Changes to Game Settings section of this guide. The ff8input.cfg file must have 0s next to the Joystick values or else the game will detect and force controller buttons instead of keyboard buttons.

I don't have a PS3 controller, so I don't know what differences it may have compared to a 360 controller. If you tried following my guide and the script doesn't work for your directional buttons, you can use this test script to find out how the directional buttons are detected in autohotkey:

https://autohotkey.com/docs/scripts/JoystickTest.htm (I know this requires learning quite a bit on how autohotkey works, but I can't do this myself without a PS3 controller)

If you need further help, I'll need specific questions on how you need help.
Moogy 25. mar. 2016 kl. 16:09 
i have a PS3 controller hooked to my PC, however i still have this B2,B3 etc crap in the config and i cant use directional buttons, only analog.
Can this help me ?
Im not sure how this works, its quite complex.

Thanks for the hard work !
dean.dip  [ophavsmand] 8. mar. 2016 kl. 22:27 
@Mehnesh Detecting up on a controller is more complicated than using JoyY instead of an up key, so that may be your problem. If you tried replacing the send parts with Joy buttons as well, then that would be a problem also since Autohotkey can't send controller buttons down or up, it can only detect the status of them.
xAbuAlix 8. mar. 2016 kl. 9:18 
Hi guys

since you talked about AHK this code is for toggling sprint on keyboard http://battlelog.battlefield.com/bf3/en/forum/threadview/2832654625151807743/

I tried to change the LShift & W to Joy11 & JoyY to toggle sprint on xbox controller but it didn't work!

Need your help
dean.dip  [ophavsmand] 12. feb. 2015 kl. 19:45 
@echoing.silently I wasn't actually using the HID version before, but I tried the new HID version and realized I actually didn't have the true defaults setup in my scripts. This script has the true defaults: http://pastie.org/pastes/9943405/text I also like the non-HID version better however because it can use a custom configuration (I dislike the default) and I can still make a script that works with that, and I already did actually. I'm updating the thread with it.