5 minutes and your script is ready, you just have to enter the model IDs. Why compile this?5 minutes and your script is ready, you just have to enter the model IDs. Why compile this?
Посмотреть вложение 115071
[CODE = lua] local imgui = require ('imgui')
local encoding = require 'encoding'
encoding.default = 'CP1251'
u8 = encoding.UTF8
local window = imgui.ImBool (false)
local font = renderCreateFont ('Tahoma', 13, 5)
local settings = {
- {'name', variable, model ID}
{'Trash', imgui.ImBool (false), 1},
{'Ore', imgui.ImBool (false), 2},
{'Treasure', imgui.ImBool (false), 3},
{'Anasha', imgui.ImBool (false), 4},
{'Gifts', imgui.ImBool (false), 5},
{'Narco', imgui.ImBool (false), 6},
{'Trash can', imgui.ImBool (false), 7},
}
function main ()
while not isSampAvailable () do wait (200) end
imgui.Process = false
window.v = true --show window
while true do
wait (0)
imgui.Process = window.v
for k, v in ipairs (getAllObjects ()) do
for i = 1, #settings do
if settings
[2] .v then
local mx, my, mz = getCharCoordinates (PLAYER_PED)
if getObjectModel (v) == settings [3] then
local result, x, y, z = getObjectCoordinates (v)
if result then
local mrx, mry = convert3DCoordsToScreen (mx, my, mz)
local rx, ry = convert3DCoordsToScreen (x, y, z)
renderDrawLine (mrx, mry, rx, ry, 3, 0xFFff004d)
renderFontDrawText (font, settings [1], rx, ry, 0xFFFFFFFF)
end
end
end
end
end
end
end
function imgui.OnDrawFrame ()
if window.v then
imgui.SetNextWindowPos (imgui.ImVec2 (350.0, 250.0), imgui.Cond.FirstUseEver)
imgui.SetNextWindowSize (imgui.ImVec2 (100.0, 185.0), imgui.Cond.FirstUseEver)
imgui.Begin ('RENDER ON', window, imgui.WindowFlags.NoResize + imgui.WindowFlags.NoCollapse)
for i = 1, #settings do
imgui.Checkbox (u8 (settings [1]), settings [2])
end
imgui.End ()
end
end [/ CODE]