local active = false
function main()
if not isSampLoaded() or not isSampfuncsLoaded() then return end
sampRegisterChatCommand('alt', function()
active = not active
if active then
sampAddChatMessage("on", -1)
else
sampAddChatMessage("off", -1)
end
end)
while true do
wait(100)
if active then
setGameKeyState(15, 255)
wait(1)
setGameKeyState(15, 0)
end
end
end