Автоган

SnaKe_15

Новичок
Автор темы
2
0
Я хочу чтобы при нажатии клавиши мне давала ган.и чего-то не получаеться вот
script_name(Test')
script_author("SnaKe")
require 'moonloader'
function main()
repeat wait(0) until isSampAvailable()
while true do wait(0)
if res and isKeyJustPressed(90) then -- Z
id = sampGetPlayerIdByCharHandle(handle)
name = sampGetPlayerNickname(id)
sampSendChat('/sellgun '..name..' eagle')
end
end
return
end
 

eenz

Известный
203
102
Lua:
function main()
    if not isSampLoaded() or not isSampfuncsLoaded() then return end
    while not isSampAvailable() do wait(100) end
    while true do wait(0)
        if wasKeyPressed(0x5A) and not sampIsChatInputActive() and not sampIsDialogActive() then
        _, id = sampGetPlayerIdByCharHandle(playerPed)
        sampSendChat('/sellgun '..sampGetPlayerNickname(id)..' deagle')
        end
    end
end