diff --git a/client.lua b/client.lua index c5fe48a..a0eb85d 100644 --- a/client.lua +++ b/client.lua @@ -109,7 +109,6 @@ RegisterNetEvent('safe:spawn', function(safeData) }) if result == 'confirm' then - lib.notify({ type = 'success', description = 'Safe recolhido com sucesso!' }) TriggerServerEvent('safe:pickup', safeData.id) else lib.notify({ type = 'inform', description = 'Operação cancelada.' }) diff --git a/server.lua b/server.lua index b7e91b2..86000e2 100644 --- a/server.lua +++ b/server.lua @@ -111,7 +111,7 @@ RegisterNetEvent('safe:place', function(type, coords, pin) if #(playerCoords - placeCoords) > PLACE_MAX_DISTANCE then dbg('safe:place REJEITADO - distância suspeita', src, #(playerCoords - placeCoords)) - return TriggerClientEvent('ox_lib:notify', src, {type='error', description='Posição inválida.'}) + return TriggerClientEvent('ox_lib:notify', src, {type='error', description='Você está muito longe para colocar o safe aqui.'}) end -- remover item @@ -196,7 +196,8 @@ RegisterNetEvent('safe:open', function(id, pin) local attempt = pinAttempts[src] if attempt and now < attempt.blockedUntil then - return TriggerClientEvent('ox_lib:notify', src, {type='error', description='Muitas tentativas erradas. Aguarde.'}) + local remaining = math.ceil(attempt.blockedUntil - now) + return TriggerClientEvent('ox_lib:notify', src, {type='error', description=('Muitas tentativas erradas. Aguarde %d segundos.'):format(remaining)}) end local safe = safes[id]