Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Rewarding Longshots Skript
- Options:
- prefix: &7[&9Rewarding Longshots&7]&r
- N: &3&l%command sender%
- command /longshots <text>:
- permission: skript.op
- trigger:
- if arg 1 is equal to "enable":
- if {longshot} is true:
- message "{@prefix} Already Enabled!"
- else:
- set {longshot} to true
- broadcast "{@prefix} Enabled by {@N}"
- else if arg 1 is equal to "disable":
- if {longshot} is false:
- broadcast "{@prefix} Already Disabled!"
- else:
- set {longshot} to false
- broadcast "{@prefix} Disabled by {@N}
- else if arg 1 is equal to "toggle":
- if {longshot} is false:
- set {longshot} to true
- broadcast "{@prefix} Enabled by {@N}
- else:
- set {longshot} to false
- broadcast "{@prefix} Disabled by {@N}
- on damage of player:
- {longshot} is true
- projectile exists
- projectile is an arrow
- set {_dist} to the distance between the victim and the attacker
- if {_dist} is between 30 and 49:
- Broadcast "{@prefix} %attacker% just got a longshot of %{_dist}% metres!"
- execute console command "/give %attacker% iron_ingot 1"
- else if {_dist} is between 50 and 99:
- Broadcast "{@prefix} %attacker% just got a longshot of %{_dist}% metres!"
- execute console command "/give %attacker% iron_ingot 1"
- execute console command "/give %attacker% gold_ingot 1"
- else if {_dist} is between 100 and 199:
- Broadcast "{@prefix} %attacker% just got a longshot of %{_dist}% metres!"
- execute console command "/give %attacker% iron_ingot 1"
- execute console command "/give %attacker% gold_ingot 1"
- execute console command "/give %attacker% diamond 1"
- else if {_dist} is greater than 200:
- Broadcast "{@prefix} %attacker% just got a longshot of %{_dist}% metres!"
- execute console command "/give %attacker% iron_ingot 2"
- execute console command "/give %attacker% gold_ingot 3"
- execute console command "/give %attacker% diamond 5"
Advertisement
Add Comment
Please, Sign In to add comment