Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- options:
- taliscolor: <##e483f2>
- talistitle: <##e483f2>Talisman &8|
- on swap hand items:
- if "%player's offtool%" contains "{@taliscolor}Talisman":
- remTalis(lore of player's offtool, player)
- send action bar "{@talistitle} &7Switched to %name of player's offtool%" to player
- wait 1 tick
- if "%player's offtool%" contains "{@taliscolor}Talisman":
- addTalis(lore of player's offtool, player)
- send action bar "{@talistitle} &7Switched to %name of player's offtool%" to player
- on inventory click:
- index of event-slot = -1:
- if "%event-slot%" contains "{@taliscolor}Talisman":
- remTalis(lore of event-slot, player)
- send action bar "{@talistitle} &7Switched to %name of event-slot%" to player
- wait 1 tick
- if "%event-slot%" contains "{@taliscolor}Talisman":
- addTalis(lore of event-slot, player)
- send action bar "{@talistitle} &7Switched to %name of event-slot%" to player
- function addTalis(l: texts, p: player):
- loop {_l::*}:
- loop-value contains "{@taliscolor}✧":
- set {_eff::*} to uncolored loop-value split at " "
- if size of {_eff::*} = 4:
- set {_eff::2} to "%{_eff::2}% %{_eff::3}%"
- set {_eff::3} to {_eff::4}
- set {_eff::2} to {_eff::2} parsed as potion effect type
- set {_x} to arabic number of {_eff::3}
- set {_x} to {_x} parsed as integer
- apply potion of {_eff::2} of tier {_x} to {_p} for 999 minutes
- function remTalis(l: texts, p: player):
- loop {_l::*}:
- loop-value contains "{@taliscolor}✧":
- set {_eff::*} to uncolored loop-value split at " "
- if size of {_eff::*} = 4:
- set {_eff::2} to "%{_eff::2}% %{_eff::3}%"
- set {_eff::2} to {_eff::2} parsed as potion effect type
- remove {_eff::2} from {_p}
- command /settalis [<integer>]:
- trigger:
- if arg 1 is 1:
- set player's tool to player's tool named "{@taliscolor}Talisman &7of Health &8(&7III&8)" with lore "", "{@taliscolor}✧ &7Regeneration III" and "{@taliscolor}✧ &7Strength III"
- else:
- set player's tool to player's tool named "{@taliscolor}Talisman &7of Speed &8(&7II&8)" with lore "", "{@taliscolor}✧ &7Speed III" and "{@taliscolor}✧ &7Jump Boost II"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement