mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-30 17:58:54 +00:00
Merge pull request #50 from SMVampire/patch-1
Fix Issues with Very Far Msgs Showing
This commit is contained in:
+4
-2
@@ -8,8 +8,10 @@ AddEventHandler('esx_rpchat:sendProximityMessage', function(playerId, title, mes
|
||||
local playerCoords = GetEntityCoords(playerPed)
|
||||
local targetCoords = GetEntityCoords(targetPed)
|
||||
|
||||
if target == player or #(playerCoords - targetCoords) < 20 then
|
||||
TriggerEvent('chat:addMessage', {args = {title, message}, color = color})
|
||||
if target ~= -1 then
|
||||
if target == player or #(playerCoords - targetCoords) < 20 then
|
||||
TriggerEvent('chat:addMessage', {args = {title, message}, color = color})
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user