Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #This skript was made by /u/AnimatedAnimater ^^
- #Feel free to edit this skript as much as you please!
- options:
- tag: &8[&7Combat Tag&8]&7
- on join:
- set {combattag::%uuid of player%} to false
- set {combattag::delay::%uuid of player%} to 0
- clear {enemy::%uuid of player%}
- on death:
- set {combattag::%uuid of victim%} to false
- set {combattag::delay::%uuid of victim%} to 0
- clear {enemy::%uuid of player%}
- on quit:
- if {combattag::%uuid of player%} is true:
- set {combattag::%uuid of player%} to false
- set {combattag::delay::%uuid of player%} to 0
- loop all players:
- if loop-player has permission "skript.spec":
- send "{@tag} &4%player% &6has combat logged" to loop-player
- set {_enemy} to {enemy::%uuid of player%}
- on damage:
- attacker is a player
- victim is a player
- attacker is in world "UHC" or "UHC_end" or "UHC_nether" or "pvp"
- victim is in world "UHC" or "UHC_end" or "UHC_nether" or "pvp"
- if {combattag::%(uuid of victim)%} is false:
- set {combattag::%(uuid of victim)%} to true
- set {combattag::delay::%(uuid of victim)%} to 30
- set {enemy::%victim%} to "%(uuid of attacker)%"
- message "{@tag} You are now combat tagged." to victim
- if {combattag::%(uuid of victim)%} is true:
- set {combattag::delay::%(uuid of victim)%} to 30
- set {enemy::%victim%} to "%(uuid of attacker)%"
- if {combattag::%(uuid of attacker)%} is false:
- set {combattag::%(uuid of attacker)%} to true
- set {combattag::delay::%(uuid of attacker)%} to 30
- set {enemy::%attacker%} to "%(uuid of victim)%"
- message "{@tag} You are now combat tagged." to attacker
- if {combattag::%(uuid of attacker)%} is true:
- set {combattag::delay::%(uuid of attacker)%} to 30
- set {enemy::%attacker%} to "%(uuid of victim)%"
- every 1 seconds:
- loop {combattag::*}:
- if {combattag::%loop-index%} is true:
- remove 1 from {combattag::delay::%loop-index%}
- if {combattag::delay::%loop-index%} is 0:
- set {combattag::%loop-index%} to false
- message "{@tag} You are no longer in combat." to %loop-value%
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement