From 4c861a6d4a4d17a981f4957a4679f6093e39644c Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Sat, 21 Dec 2024 19:50:01 +0300 Subject: [PATCH] client: register joysupported cvar to be able to use gamepads on HL25 --- cl_dll/input_goldsource.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cl_dll/input_goldsource.cpp b/cl_dll/input_goldsource.cpp index d3517b288..26567c0a6 100644 --- a/cl_dll/input_goldsource.cpp +++ b/cl_dll/input_goldsource.cpp @@ -1614,6 +1614,11 @@ void GoldSourceInput::IN_Init (void) joy_wwhack1 = gEngfuncs.pfnRegisterVariable ( "joywwhack1", "0.0", 0 ); joy_wwhack2 = gEngfuncs.pfnRegisterVariable ( "joywwhack2", "0.0", 0 ); + // HL25 checks this cvar and if it doesn't exist or set to zero + // it will lock any usage of gamepads + // see: https://github.com/ValveSoftware/halflife/issues/3621 + gEngfuncs.pfnRegisterVariable( "joysupported", "1", 0 ); + m_customaccel = gEngfuncs.pfnRegisterVariable ( "m_customaccel", "0", FCVAR_ARCHIVE ); m_customaccel_scale = gEngfuncs.pfnRegisterVariable ( "m_customaccel_scale", "0.04", FCVAR_ARCHIVE ); m_customaccel_max = gEngfuncs.pfnRegisterVariable ( "m_customaccel_max", "0", FCVAR_ARCHIVE );