local font = renderCreateFont("Arial",9,5)
local timer = 0
local x = 500
local y = 500
function calc()
lua_thread.create(function()
timer = 60
while timer > 0 do
wait(1000)
timer = timer - 1
end
end)
end
function main()
repeat wait(100) until isSampAvailable()
sampRegisterChatCommand("drugs", function()
sampSendChat("/usedrugs 3")
calc()
end)
while true do
wait(0)
if timer > 0 then
renderFontDrawText(font, timer.." sec", x, y, 0xFFFFFFFF)
end
end
end