Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2018
458
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.55 KB | None | 0 0
  1. function main()
  2. sampRegisterChatCommand("givemoney", func)
  3. wait(-1)
  4. end
  5.  
  6. function func(param)
  7.     id, money = param:match("^(%d+)%s+(%d+)$")
  8.     if id ~= nil and money ~= nil then
  9.     id1 = tonumber(id); money1 = tonumber(money)
  10.     colvo = 0
  11.     lua_thread.create(function()
  12.         repeat
  13.         sampSendChat("/pay "..id.." 5000")
  14.         colvo = colvo + 5000
  15.         wait(2100)
  16.         until colvo >= money1
  17.         sampAddChatMessage("Вы успешно передали "..colvo, -1)
  18.         colvo = 0
  19.         end)
  20.     else sampAddChatMessage("Введите \"/givemoney [id] [money]", -1)
  21.     end
  22. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement