- 14
- 0
LUA:
lua_thread.create(function() -- Рендер
while true do
wait(0)
for k, v in pairs(getAllChars()) do
local _, id = sampGetPlayerIdByCharHandle(v)
local nick = sampGetPlayerNickname(id)
for i, j in pairs(memberslist) do if nick == j then
if isCharOnScreen(v) then
local _, myid = sampGetPlayerIdByCharHandle(PLAYER_PED)
local x, y, z = getCharCoordinates(v)
local mX, mY, mZ = getCharCoordinates(PLAYER_PED)
local dist = getDistanceBetweenCoords3d(x, y, z, mX, mY, mZ)
if dist <= 10 and id == myid then
local rx, ry = convert3DCoordsToScreen(x, y, z)
renderFontDrawText(dx9font, "HEAVEN-DOKS", rx - (renderGetFontDrawTextLength(dx9font, "HEAVEN-DOKS") / 2), ry, 0xFF139BEC) -- рисуем текст
end
end