function main()
while not isSampAvailable() do wait(100) end
sampRegisterChatCommand("gotest", test)
while true do wait(0)
if state then
sampAddChatMessage("SPAM SPAM SPAM SPAM SPAM",-1)
end
end
end
function test()
state = not state
if state then
printStyledString("ENABLE", 3000, 7)
else
printStyledString("OFF", 3000, 7)
end
end