[English] Modify Controls / Keybindings (without external tools)

  • Greetings!


    We are going to go through the process of modifying the controls for The Guild II.
    I have not seen a consistent method before on the internet and after spending some time searching and experimenting, I think I finally found a way!
    After doing these steps I was able to change the camera controls to fit my keyboard layout (ZQSD instead of WASD).


    Feel free to give it a try and let me know if you are successful on your side.


    Here is the quick explanation.

    • Close the game. This is important as the game will only register changes at the next startup.
    • Go to your game folder.

      • On Windows for Steam users, this is usually located here: C:\Program Files (x86)\Steam\steamapps\common\The Guild II Renaissance.
      • On Linux for Proton/Wine users, this is usually located here: ~/.steam/steam/SteamApps/common/.
    • Open the file named input.ini with any text editor. Notepad++ is recommended. This file is really confusing at first as the value are not easily readable, but don't worry we are going to go through them.
    • Make the changes we will see below and save the file. These changes consist in switching integer (number) values in the file. Read more below to go in-depth about this.
    • Launch the game as you usually do. Enjoy your new controls/keybinds!


    And now, here is the in-depth explanation on how to choose the integer values.


    The input.ini file is a configuration file, each control has 4 values as presented below. Let's take the example of the key to toggle the HUD on and off:


    Code: input.ini
    "TOGGLE_HUD"
    2000
    35
    -1


    • First, you have the Identifier, which is a string. In our example, this is "TOGGLE_HUD". This helps knowing what control you are modifying, and the identifiers are, thankfully, straightforward.
    • The second value is 2000 when it corresponds to a keyboard key and 2100 when it corresponds to a mouse binding. It seems like it is for the input device ID. This is not important for what we are trying to do, just like the last value which is a boolean of either -1 or 0.
    • The part that interests us the most is the third entry, which is an integer between 1 and 221.
      This third value corresponds to a keycode on your keyboard. This is simply the integer value representation of when a key is pressed.

    The "KeyCode" used in this third value corresponds to a specific SDL (Simple DirectMedia Layer) table. SDL is a game and software development library that, among other things, serves as an input devices communication layer. It seems to have been used by The Guild II.


    Here is the table I have been able to put together from my experiments. You can also download it as a txt file in the attachments of this post:



    In this table, you have two values available per line:

    • First value corresponds to the KeyCode you have to use in the input.ini file.
    • Second value is a visual, readable string corresponding to the keycode.


    :?: This is important to note that these values are adapting to your keyboard layout: this means "A" will really be the "A" key from your keyboard, and not just a QWERTY layout. So make sure to pick the value according to your keyboard layout directly!


    :?: Some controls listed in input.ini are not actively used in game. For example, it seems that the "QUICKLOAD" control, although listed in the file, is not working in game regardless of the keycode entered.


    I do hope that the table works for everyone and is not specific to me, so let me know if you come across any issue and I will try to work it out for everyone!
    At some point I might as well work on a small external GUI tool to easily change the controls, but for now you have all the info you need to enjoy custom controls without the need of an external remapper!


    Have a good day and take care. :thumbup: