Вы используете устаревший браузер. Этот и другие сайты могут отображаться в нём некорректно. Вам необходимо обновить браузер или попробовать использовать другой.
Как написать функцию, чтобы например человек в бинде выбрал отыгровку, она начала играть и он, например, нажимает клавишу END и отыгровка прекращается и в чат пишется, что отыгровка остановлена?
require "lib.moonloader"
function main()
while true do
wait(0)
if isKeyJustPressed(VK_Y) and not sampIsChatInputActive() and not sampIsDialogActive() and not isSampfuncsConsoleActive() then
thread = lua_thread.create(function()
sampSendChat('Один')
wait(1000)
sampSendChat('Два')
wait(1000)
sampSendChat('Три')
wait(1000)
sampSendChat('Четыре')
wait(1000)
sampSendChat('Пять')
end)
end
if isKeyJustPressed(VK_END) and not sampIsChatInputActive() and not sampIsDialogActive() and not isSampfuncsConsoleActive() and thread then...
require "lib.moonloader"
function main()
while true do
wait(0)
if isKeyJustPressed(VK_Y) and not sampIsChatInputActive() and not sampIsDialogActive() and not isSampfuncsConsoleActive() then
thread = lua_thread.create(function()
sampSendChat('Один')
wait(1000)
sampSendChat('Два')
wait(1000)
sampSendChat('Три')
wait(1000)
sampSendChat('Четыре')
wait(1000)
sampSendChat('Пять')
end)
end
if isKeyJustPressed(VK_END) and not sampIsChatInputActive() and not sampIsDialogActive() and not isSampfuncsConsoleActive() and thread then
thread:terminate()
thread = nil
sampAddChatMessage('Отыгровка остановлена', -1)
end
end
end