mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-09-04 16:23:21 +00:00
Fix loop limit error
Resolves the "attempt to get length" error, which caused that the robbery didn't stop when being too far from the zone, and sending notification to police officers. Tested and working.
This commit is contained in:
+1
-1
@@ -11,7 +11,7 @@ end
|
||||
RegisterServerEvent('esx_holdup:toofar')
|
||||
AddEventHandler('esx_holdup:toofar', function(robb)
|
||||
local _source = source
|
||||
local xPlayer = ESX.GetPlayerFromId(_source)
|
||||
local xPlayers = ESX.GetPlayers()
|
||||
rob = false
|
||||
for i=1, #xPlayers, 1 do
|
||||
local xPlayer = ESX.GetPlayerFromId(xPlayers[i])
|
||||
|
||||
Reference in New Issue
Block a user