patison234

WhiteList Beta v. 1.0 [Skript 2.0.2]

Dec 7th, 2013
1,440
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 7.27 KB | None | 0 0
  1. # # # # # # # # # # # # # # # #
  2. # Script by PatisonPlayGames  #
  3. # Name: WhiteList             #
  4. # Version: Beta 1.0           #
  5. # Skript: 2.0.2               #
  6. # # # # # # # # # # # # # # # #
  7.  
  8.  
  9.  
  10. #=============================================#
  11. #  Licencja WhiteList by PatisonPlayGames!    #
  12. # + Nie zezwalam na:                          #
  13. # - Usuwanie tresci o autorze!                #
  14. # - Udostepnaniu skryptu innym!               #
  15. # - Podszywanie sie pod autora!               #
  16. # - Uzywanie kodu skryptu w swoich skryptach! #
  17. # - Zarabianie na skrypcie!                   #
  18. # + Zezwalam na:                              #
  19. # - Dodawanie kodu na swoja potrzebe!         #
  20. # - Modyfikowanie wiadomosci!                 #
  21. #=============================================#
  22.  
  23. options:
  24. # # # # # # # # # # # # # # #
  25. #                           #
  26. #       General Config      #
  27. #                           #
  28. # # # # # # # # # # # # # # #
  29.  
  30.  
  31.  
  32.     # Komenda uzywana w skrypcie:
  33.     komenda: whitelist
  34.     # Skroty do komendy wyzej:
  35.     aliasy: wl
  36.     # Tag wyswietlany przed wiadomosciami skryptu! 
  37.     tag: &8[&3WhiteList&8]
  38.     #Nazwa pliku sk.Zanim wgrasz plik i zmieniles nazwe zmien ja takze tutaj i dopiero wgraj plik!:
  39.     sk: WhiteList
  40.    
  41.    
  42.    
  43.    
  44. # # # # # # # # # # # # # #
  45. #                         #
  46. #       Permissions       #
  47. #                         #
  48. # # # # # # # # # # # # # #
  49.  
  50.  
  51.  
  52.     # Wiadomosc przy braku uprawnienia:
  53.     permission: &4Nie masz uprawnien by uzywac tej komendy!
  54.  
  55.  
  56.    
  57. # Autor Config
  58.     version: Beta 1.1
  59.    
  60. variables:
  61.     {whitelist.%player%.allow} = true
  62.     {whitelist.list::*} = 0
  63.     {whitelist.on} = false
  64. # Basic WhiteList Command
  65.  
  66. command /{@komenda} [<text>] [<text>]:
  67.     aliases: {@aliasy}
  68.     trigger:
  69.         if arg 1 is not set:
  70.             send "&7=========&cWhite-List&7============="
  71.             send "&c/{@komenda} dodaj [Gracz] - &3Dodaje gracza do White-Listy!"
  72.             send "&c/{@komenda} usun [Gracz] - &3Usuwa gracza z White-Listy!"
  73.             send "&c/{@komenda} ustaw [Wiadomosc] - &3Ustawia wiadomosc wywalenia gdy gracz probuje wbic na serwa!"
  74.             send "&c/{@komenda} on - &3Wlacza White-Liste!"
  75.             send "&c/{@komenda} off - &3Wylacza White-Liste!"
  76.             send "&c/{@komenda} lista - &3Pokazuje liste garczy na White-Liscie!"
  77.             send "&c/{@komenda} autor - &3Pokazuje autora skryptu!"
  78.             send "&c/{@komenda} reload - &3Przeladowywuje config!"
  79.             stop
  80.         if arg 1 is "help" or "pomoc":
  81.             send "&7=========&cWhite-List&7============="
  82.             send "&c/{@komenda} dodaj [Gracz] - &3Dodaje gracza do White-Listy!"
  83.             send "&c/{@komenda} usun [Gracz] - &3Usuwa gracza z White-Listy!"
  84.             send "&c/{@komenda} ustaw [Wiadomosc] - &3Ustawia wiadomosc wywalenia gdy gracz probuje wbic na serwa!"
  85.             send "&c/{@komenda} on - &3Wlacza White-Liste!"
  86.             send "&c/{@komenda} off - &3Wylacza White-Liste!"
  87.             send "&c/{@komenda} lista - &3Pokazuje liste garczy na White-Liscie!"
  88.             send "&c/{@komenda} autor - &3Pokazuje autora skryptu!"
  89.             send "&c/{@komenda} reload - &3Przeladowywuje config!"
  90.             stop
  91.         if arg 1 is "dodaj" or "add":
  92.             if player has permission "wl.admin":
  93.                 if arg 2 is player:
  94.                     set {_x} to arg 2 parsed as player
  95.                     send "{@tag} &aGracz &6%{_x}%&azostal dodany do whitelisty!"
  96.                     set {whitelist.%{_x}%.allow} to false
  97.                     add "%{_x}%" to {whitelist.list::*}
  98.                     stop
  99.                 else:
  100.                     send "{@tag} &cPodaj nick gracza!"
  101.                     stop
  102.             else:
  103.                 send "{@tag} {@permission}"
  104.                 stop
  105.         if arg 1 is "remove" or "usun":
  106.             if player has permission "wl.admin":
  107.                 if arg 2 is player:
  108.                     set {_z} to arg 2 parsed as player
  109.                     if {whitelist.%{_z}%.allow} is false:
  110.                         remove "%{_z}%" from {whitelist.list::*}
  111.                         set {whitelist.%{_z}%.allow} to true
  112.                         send "{@tag} &aGracz &6%{_z}% &a zostal usuniety z whitelisty!"
  113.                         stop
  114.                     else:
  115.                         send "{@tag} &cTen gracz nie znajduje sie na whiteliscie!"
  116.                         stop
  117.                 else:
  118.                     send "{@tag} &cPodaj nick gracza!"
  119.                     stop
  120.             else:
  121.                 send "{@tag} {@permission}"
  122.                 stop
  123.         if arg 1 is "set" or "ustaw":
  124.             if player has permission "wl.admin":
  125.                 if arg 2 is set:
  126.                     set {_y} to arg 2 parsed as text
  127.                     clear {kickmsg}
  128.                     set {kickmsg} to {_y}
  129.                     send "{@tag} &aWiadomosc zostala ustawiona na: &6%{kickmsg}%"
  130.                     stop
  131.                 else:
  132.                     send "{@tag} &cPodaj wiadomosc!"
  133.                     stop
  134.             else:
  135.                 send "{@tag} {@permission}"
  136.                 stop
  137.         if arg 1 is "on":
  138.             if player has permission "wl.admin":
  139.                 if {whitelist.on} is false:
  140.                     set {whitelist.on} to true
  141.                     send "{@tag} &aWhiteLista zostala wlaczona!"
  142.                     stop
  143.                 else:
  144.                     send "{@tag} &cWhiteLista jest juz aktywna!"
  145.                     stop
  146.             else:
  147.                 send "{@tag} {@permission}"
  148.                 stop
  149.         if arg 1 is "off":
  150.             if player has permission "wl.admin":
  151.                 if {whitelist.on} is true:
  152.                     set {whitelist.on} to false
  153.                     send "{@tag} &aWhiteLista zostala wylaczona!"
  154.                     stop
  155.                 else:
  156.                     send "{@tag} &cWhiteLista jest juz wylaczona!"
  157.                     stop
  158.             else:
  159.                 send "{@tag} {@permission}"
  160.                 stop
  161.         if arg 1 is "list" or "lista":
  162.             if player has permission "wl.admin":
  163.                 send "{@tag} Gracze na white-liscie: &6%{whitelist.list::*}%"
  164.                 stop
  165.             else:
  166.                 send "{@tag} {@permission}"
  167.                 stop
  168.         if arg 1 is "reload" or "przeladuj":
  169.             if player has permission "wl.admin":
  170.                 execute console command "skript reload {@sk}"
  171.                 send "{@tag} &aPrzeladowano!"
  172.                 stop
  173.             else:
  174.                 send "{@tag} {@permission}"
  175.                 stop
  176.         if arg 1 is "wersja" or "version":
  177.             send "&7----------------------------------------------"
  178.             send " &8Nazwa: &aWhiteList"
  179.             send " &8Wersja: &a&n{@version}"
  180.             send "&7----------------------------------------------"
  181.             stop
  182.         if arg 1 is "author" or "autor":
  183.             send "&7----------------------------------------------"
  184.             send " &8Autor: &aPatisonPlayGames"
  185.             send " &8Nazwa: &aSWhiteList"
  186.             send "&8 &8&nYou&4&nTube:&a &nwww.youtube.com/PatisonPlayGames"
  187.             send "&7----------------------------------------------"
  188.             stop
  189.         if arg 1 is not "author" or "autor" or "wersja" or "version" or "reload" or "przeladuj" or "list" or "lista" or "off" or "on" or "set" or "ustaw" or "add" or "dodaj" or "remove" or "usun":
  190.             send "{@tag} &4Nie ma takiej komendy! &aWpisz /{@komenda}!"
  191.             stop
  192.  
  193. on connect:
  194.     if {whitelist.on} is true:
  195.         if {whitelist.%player%.allow} is true:
  196.             kick the player due to "%{kickmsg}%"
  197.             stop
  198.  
  199. on skript start:
  200.     send "&8WhiteList wymaga wersji Skript 2.0.2 ..." to the console
  201.     wait 1 seconds
  202.     send "&8Serwer pracuje na wersji: %skript version%" to the console
  203.     send "" to the console
  204.     send "&8--------------------------------------------------------------" to the console
  205.     send "&8|                                                            |" to the console
  206.     send "&8|                  Enable &9WhiteList                      &8|" to the console
  207.     send "&8|                                                            |" to the console
  208.     send "&8--------------------------------------------------------------" to the console
  209.     send "" to the console
  210.     send "&8Autor: &ePatisonPlayGames" to the console
  211.     send "&8Version: &7{@version}" to the console
  212.     send "" to the console
  213.  
  214.  
  215. #------------------------------------------------ End of Script / Thanks for Use ---------------------------------#
  216. #-------------------------------- © by PationPlayGames - Author / YouTube www.youtube.com/PatisonPlayGames -------#
Advertisement
Add Comment
Please, Sign In to add comment