local on = require "lib.samp.events"
local imgui = require 'imgui'
local main_window_state = imgui.ImBool(false)
local t = {}
function imgui.OnDrawFrame()
if main_window_state.v then
imgui.SetNextWindowSize(imgui.ImVec2(150, 200), imgui.Cond.FirstUseEver)
imgui.Begin('My window', main_window_state)
for i = 1, #t do imgui.Text(t[i]) end
imgui.End()
end
end
function main()
while true do wait(0)
imgui.Process = main_window_state.v
end
end
function on.onServerMessage(color, text)
if text:find('Ранг') then
table.insert(t, text)
main_window_state.v = not main_window_state.v
end
end