darei

детектор пидаров

Sep 22nd, 2021
888
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local component = require("component")
  2. local computer = require("computer")
  3. -----Ники в вайте не пишет в чат-----
  4. local whitelist = {['Exozze'] = true}
  5. local term = require("term")
  6. local t = require("table")
  7. local event = require("event")
  8. local gpu = component.gpu
  9. local r = component.radar
  10. local chat = component.chat_box
  11. local players = {}
  12. chat.setName("§2ВНИМАНИЕ'§7")
  13.  
  14. print("Вывод ников в чат игры(Y/N):")
  15. conf = io.read()
  16.  
  17. function palevo()
  18.   local scan = r.getPlayers()
  19.   for i = 1, #scan do
  20.    if not whitelist[scan[i].name] then
  21.     t.insert(players, scan[i].name)
  22.    end
  23.   end
  24.   local info = t.concat(players,",")
  25.   if conf == "Y" or conf == "y" then
  26.    chat.say("§9На территории замечен: §4" ..info)
  27.   end
  28.   print("Замечен:")
  29.   print(info)
  30.   players = {}
  31.   os.sleep(30)
  32. end
  33.  
  34. while true do
  35.   local scan_a = r.getPlayers()
  36.   if r.getPlayers() then
  37.    for j = 1, #scan_a do
  38.     if not whitelist[scan_a[j].name] then
  39.       palevo()
  40.     end
  41.    end
  42.   end
  43. end
RAW Paste Data