DominikCiupa3

Untitled

Sep 6th, 2014
248
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.55 KB | None | 0 0
  1. variables:
  2.     {_wolnyram} = 0
  3.     {_ping.%player%} = 0
  4.     {_ram} = 0
  5.     {_tps} = 0
  6.     {_port} = 0
  7.     {_bukkit} = 0
  8.     {_iloscslotow} = 0
  9.     {_antiddos} = 0
  10. options:
  11.     ping : 300
  12.     atak : 5
  13. command /GLaDOS [<text>] [<text>]:
  14.     trigger:
  15.         if arg 1 is "ram":
  16.             give 1 cat disc named "<green>Ram" to the player
  17.             stop
  18.         if arg 1 is "ping":
  19.             set {_ping.%player%} to player's ping
  20.             wait a tick
  21.             send "<green>Twój ping to: <blue>%{_ping.%player%}%"
  22.         if arg 1 is "info":
  23.             set {_ip} to server's ip
  24.             set {_port} to server's port
  25.             set {_tps} to tps
  26.             set {_bukkit} to bukkit version
  27.             set {_iloscslotow} to max players
  28.             set {_ram} to max memory
  29.             send "<blue>============<red>GLaDOS<blue>============"
  30.             send "<green>Adres IP serwera :<yellow> %{_ip}%"
  31.             send "<green>Port serwera : <yellow>%{_port}%"
  32.             send "<green>Wersja silnika CraftBukkit : <yellow>%{_bukkit}%"
  33.             send "<green>Ilość slotów oraz maksymalna ilość ramu :<yellow> %{_ram}%B na %{_iloscslotow}% osób"
  34.             send "<orange>Na każdą osobę powinno przypadać około 200 MB ramu czyli około 200 000 000 B"
  35.         if arg 1 is "procedura":
  36.             if arg 2 is "uruchom":
  37.                 execute console command "/save-all"
  38.                 wait 2 seconds
  39.                 execute console command "/stop <red>GLaDOS : Uruchomiłam procedurę antiDDos."
  40.             if arg 2 is "pomoc":
  41.                 send "<green>Procedura obronna w razie wypadku ataku botów lub ataku typu DDos"
  42.                 send "<yellow>==========================================="
  43.                 send "<green>Krok 1 - Zapisuje mapę"
  44.                 send "<green>Krok 2 - Wyłącza serwer"
  45.                 send "<orange>GLaDOS nie jest w stanie włączyć serwera. Musisz to zrobić manualnie."
  46.         if arg 1 is "aktualizuj":
  47.             delete file /plugins/Skript/scripts/GLaDOS.sk
  48.             download from %string% to file /plugins/Skript/scripts/GLaDOS.sk
  49.         if arg 1 is "test":
  50.             broadcast "test"
  51.  
  52. on rightclick holding cat disc:
  53.     name of player's held item is "<green>Ram":
  54.         cancel event
  55.         set {_wolnyram} to free memory
  56.         wait a tick
  57.         set {_ram} to max memory
  58.         display "<green>Ilość wolnej pamięci ram :<blue> %{_wolnyram}%B<green> z : <blue>%{_ram}%B" on bossbar for player
  59.  
  60. on any move:
  61.     set {_ping.%player%} to player's ping
  62.     wait a tick
  63.     if {_ping.%player%} is bigger than {@ping}:
  64.         kick the player by reason of "&4Twój ping przekracza {@ping} co powoduje przeciążenie serwera. Wyłącz pobieranie, przeglądarke, komunikatory typu Skype itp."
  65. on chat:
  66.     replace all "chuj" and "huj" and "kurwa" and "spierdalaj" and "fuck" with "(<orange>GLaDOS :<red> Graczu <blue>%player%<red> nie używaj takich słów.)" in the message
Advertisement
Add Comment
Please, Sign In to add comment