on join: if {pvp::%player%} is not set: set {pvp::%player%} to false set {pvpczas::%player%} to 0 if player has permission "antylogout.bypass": if {pvpbypass::%player%} is not set: set {pvpbypass::%player%} to false command /antylogout : usage: &cPoprawne użycie: &e/antylogout wlacz/wylacz &c- włącza lub wyłącza bypass na antylogout. permission: antylogout.bypass permission message: &cBambiku, nie masz dostępu do tej komendy :( trigger: if arg 1 is not "wlacz" or "wylacz": send "&bAntyLogOut &e» &cPoprawne użycie: &e/antylogout wlacz/wylacz &c- włącza lub wyłącza bypass na antylogout." stop if arg 1 is "wlacz": send "&bAntyLogOut &e» &aWłączono Bypass przed AntyLogOut" set {pvp.%player%.bypass} to true stop if arg 1 is "wylacz": send "&bAntyLogOut &e» &aWyłączono Bypass przed AntyLogOut" set {pvp.%player%.bypass} to false stop on command: if {pvp::%player%} is true: cancel event send "&bAntyLogOut &e» &cWpisywanie komend podczas PvP jest zablokowane!" to sender stop else: stop on damage: if attacker is player: if victim is player: if {pvpbypass::%attacker%} and {pvpbypass::%victim%} is false: if {pvp::%attacker%} is false: set {pvp::%attacker%} to true set {pvp::%victim%} to true send "&bAntyLogOut &e» &cZaatakowałeś &e%victim%&c! &cNie wychodź z gry, bo w przeciwnym razie zginiesz! Odczekaj &e30 sekund&c!" to attacker send "&bAntyLogOut &e» &cZostałeś zaatakowany przez &e%attacker%&c! &cNie wychodź z gry, bo w przeciwnym razie zginiesz! Odczekaj &e30 sekund&c!" to victim set {pvpczas::%attacker%} to 31 set {pvpczas::%victim%} to 31 stop else: set {pvpczas::%attacker%} to 31 set {pvpczas::%victim%} to 31 stop else: stop on disconnect: if {pvp::%player%} is true: kill player send "&bAntyLogOut &e» &e%player% &cwyszedł podczas walki!" to all players set {pvp::%player%} to false set {pvpczas::%player%} to 0 stop else: stop on death: if {pvp::%player%} is true: set {pvp::%player%} to false set {pvpczas::%player%} to 0 stop every 1 second: loop all players: if {pvp::%loop-player%} is true: remove 1 from {pvpczas::%loop-player%} set action bar of loop-player to "&c&lJESTEŚ W TRAKCIE WALKI! POZOSTAŁO: &e&l%{pvpczas::%loop-player%}% &c&lSEKUND!" if {pvpczas::%loop-player%} is less than or equal to 1: set {pvpczas::%loop-player%} to 0 set {pvp::%loop-player%} to false send "&bAntyLogOut &e» &aBitwa się zakończyła, możesz spokojnie się wylogować i wpisywać komendy!" to loop-player stop else: stop