From 163dbd315edf498b39aeb1474dbc4df634f6fce7 Mon Sep 17 00:00:00 2001 From: terhalangkasta <136704151+terhalangkasta@users.noreply.github.com> Date: Thu, 13 Nov 2025 23:35:34 +0700 Subject: [PATCH 1/2] feat(interface/progress): support cancelprogress keybind in RedM - Added support for RedM game controls and progress cancellation. - Added a lightweight thread to detect X key manually in RedM, with a cooldown to prevent spam. Signed-off-by: terhalangkasta <136704151+terhalangkasta@users.noreply.github.com> --- resource/interface/client/progress.lua | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/resource/interface/client/progress.lua b/resource/interface/client/progress.lua index 444371b81..c787569ea 100644 --- a/resource/interface/client/progress.lua +++ b/resource/interface/client/progress.lua @@ -58,6 +58,7 @@ local function interruptProgress(data) end local isFivem = cache.game == 'fivem' +local isRedm = cache.game == 'redm' local controls = { INPUT_LOOK_LR = isFivem and 1 or 0xA987235F, @@ -227,6 +228,19 @@ if isFivem then RegisterKeyMapping('cancelprogress', locale('cancel_progress'), 'keyboard', 'x') end +if isRedM then + CreateThread(function() + while true do + Wait(100) + if lib.progressActive() and IsControlPressed(0, 0x8CC9CD42) then + ExecuteCommand('cancelprogress') + Wait(500) + end + end + end) +end + + local function deleteProgressProps(serverId) local playerProps = createdProps[serverId] From bf5b765f80ae5ce08bac15207e33ab4d2d07d857 Mon Sep 17 00:00:00 2001 From: terhalangkasta <136704151+terhalangkasta@users.noreply.github.com> Date: Sun, 16 Nov 2025 18:55:43 +0700 Subject: [PATCH 2/2] Fix case sensitivity for isRedM check Signed-off-by: terhalangkasta <136704151+terhalangkasta@users.noreply.github.com> --- resource/interface/client/progress.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/resource/interface/client/progress.lua b/resource/interface/client/progress.lua index c787569ea..eb575922b 100644 --- a/resource/interface/client/progress.lua +++ b/resource/interface/client/progress.lua @@ -228,7 +228,7 @@ if isFivem then RegisterKeyMapping('cancelprogress', locale('cancel_progress'), 'keyboard', 'x') end -if isRedM then +if isRedm then CreateThread(function() while true do Wait(100) @@ -240,7 +240,6 @@ if isRedM then end) end - local function deleteProgressProps(serverId) local playerProps = createdProps[serverId]