Skip to content

Instantly share code, notes, and snippets.

@jonfk
Last active October 29, 2025 09:28
Show Gist options
  • Select an option

  • Save jonfk/17cfc84936ffd7b8203378a778ade982 to your computer and use it in GitHub Desktop.

Select an option

Save jonfk/17cfc84936ffd7b8203378a778ade982 to your computer and use it in GitHub Desktop.
Fix to use dualsense controller in hollow knight on linux

Map dualsense controller manually and disable Steam Input

This fixes the issue of swapped buttons and Triggers in the dualsense controller opening the pause menu The issue is caused by the SDL version used by hollow knight not recognizing the dualsense controller and mapping buttons properly. It is also not helped by steam input not disabling the native controller support when used in hollow knight. The issue cannot be fixed by simple mapping in steam input.

  1. Disable Steam Input
  2. Set the following as launch option
SDL_GAMECONTROLLERCONFIG="050000004c050000e60c000000810000,Sony DualSense ,a:b0,b:b1,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b10,leftshoulder:b4,leftstick:b11,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b12,righttrigger:a5,rightx:a3,righty:a4,start:b9,x:b3,y:b2,platform:Linux," %command%

Use libSDL2 from Steam runtime:

If the above doesn't work. Try the following.

From @vyivel

You can also try making the game use libSDL2 from Steam runtime

SDL_DYNAMIC_API=/home/USERNAME/.steam/root/ubuntu12_32/steam-runtime/usr/lib/x86_64-linux-gnu/libSDL2-2.0.so.0 %command%

(where USERNAME should be replaced with your OS user name)

@mad-the-one
Copy link

@ExtraBurrito Have you tried to follow the path in the command? Maybe you have debian or an other distribution so you need to alter the command like @CWinarski did. The path only points to the installed driver

@ExtraBurrito
Copy link

@mad-the-one No, i have cachyos - Arch based distro, I tried to find the file manually in this path and found it with exactly the same name

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment