require 'lib.moonloader'
font = renderCreateFont('Century Gothic', 12, 5)
function main()
repeat wait(0) until isSampAvailable()
wait(3001)
while true do
wait(0)
if active2 then
for _, v in pairs(getAllObjects()) do
if isObjectOnScreen(v) then
local result, oX, oY, oZ = getObjectCoordinates(v)
local x1, y1 = convert3DCoordsToScreen(oX,oY,oZ)
local objmodel = getObjectModel(v)
local x2,y2,z2 = getCharCoordinates(PLAYER_PED)
local x10, y10 = convert3DCoordsToScreen(x2,y2,z2)
distance = string.format("%.0f", getDistanceBetweenCoords3d(oX,oY,oZ, x2, y2, z2))
if objmodel == 1440 then renderDrawLine(x10, y10, x1, y1, 1.1, 0xFFD00000) renderFontDrawText(font,"{52af71}«аброшенный контейнер найден!\nƒистанци¤: "..distance, x1, y1, -1) end
end
end
end
end
end