From 67e3dd5e0039e5f7f4a4a83c20cf5740d68c3063 Mon Sep 17 00:00:00 2001 From: RoadToSix <92928205+roadtosixx@users.noreply.github.com> Date: Sat, 29 Oct 2022 01:32:24 +0200 Subject: [PATCH] fix(esx_banking): ATM could be opened everywhere --- [esx_addons]/esx_banking/client/main.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/[esx_addons]/esx_banking/client/main.lua b/[esx_addons]/esx_banking/client/main.lua index 2c60fe9f..342eefb9 100644 --- a/[esx_addons]/esx_banking/client/main.lua +++ b/[esx_addons]/esx_banking/client/main.lua @@ -172,11 +172,11 @@ local function StartThread() PedHandler(closestPed) end - if not isInMenu and IsPedOnFoot(PlayerPedId()) then + if IsPedOnFoot(PlayerPedId()) then local closestBank = {} for i = 1, #Config.AtmModels do - local atm = GetClosestObjectOfType(_GetEntityCoords, 3.0, Config.AtmModels[i], false) + local atm = GetClosestObjectOfType(_GetEntityCoords, 8.0, Config.AtmModels[i], false) if atm ~= 0 then local atmOffset = GetOffsetFromEntityInWorldCoords(atm, 0.0, -0.7, 0.0) local atmHeading = GetEntityHeading(atm)