View difference between Paste ID: NGtpMpMd and h7MPyXSK
SHOW: | | - or go back to the newest paste.
1
on join:
2
	set {pvp.%player%} to 0
3
 
4
5
6
on damage:
7
	if attacker has permission "pvp.bypass":
8
		if {pvp.%victim%} is 0:
9
			if {pvp.%attacker%} is 0:
10
	 			stop			
11
	else:
12
		if {pvp.%victim%} is 0:
13
			if {pvp.%attacker%} is 0:
14
				set {pvp.%victim%} to 1
15
				set {pvp.%attacker%} to 1
16
				send "&cVoce entrou em combate com &c&l%victim%" to attacker
17
				send "&cVoce entrou em combate com &c&l%attacker%" to victim			
18
				wait 9 real seconds
19
				send "&cVoce saiu de combate com &c&l%victim%" to attacker
20
				send "&cVoce saiu de combate com &c&l%attacker%" to victim
21
				set {pvp.%victim%} to 0
22
				set {pvp.%attacker%} to 0
23
on quit:
24
	if {pvp.%player%} is 1:
25
		kick player due to "&cBanido por fugir em pvp"
26
		broadcast "&c&l%player%&c levou ban por fugir em pvp por 1 minuto"	
27-
		ban the player due to "&c&l%player%&c levou ban por fugir em pvp por 1 minuto"		
27+
28
		ban player due to "&c&l%player%&c levou ban por fugir em pvp por 1 minuto"		
29
		wait 1 minute
30
		unban the player
31
	else:
32
		teleport player to spawn