Just so you know, we don't know the file format for every file. If it's just a bunch of random characters, it's probably a .zip or .jar.
# Author: i998979
# Script & API thread: https://forums.skunity.com/t/process-bar-a-shortcut-for-making-skills-cooldown/6321
command /processbar [<text>] [<text>] [<text>] [<text>] [<text>] [<text>] [<text>] [<text>]:
aliases: /pb, /pbar
trigger:
if arg-1 is "help":
message "&2----------&a[&1ProcessBar&a]&2----------"
message "&a/ProcessBar [arg-1] [arg-2] [arg-3] [arg-4] [arg-5]"
message "&a arg-1:&e [ActionBar | Title | SubTitle | Message]"
message "&a arg-2:&e [Total length of bar]"
message "&a arg-3:&e [Cooldown per change] "
message "&a arg-4:&e [Increase part (3 characters, include color code)]"
message "&a arg-5:&e [Decrease part (3 characters, include color code)]"
message "&a arg-6:&e [Staytime of bar (Title, SubTiele only)]"
message "&a arg-7:&e [Fade in of bar (Title, SubTiele only)]"
message "&a arg-8:&e [Fade out of bar (Title, SubTiele only)]"
message "&2----------&a[&1ProcessBar&a]&2----------"
else if arg-1 is set:
if arg-2 parsed as integer is set:
if arg-3 parsed as integer is set:
if arg-4 is set:
if arg-5 is set:
set {PB.Increase} to ""
set {PB.Decrease} to ""
loop (arg-2 parsed as integer+2) times:
set {_PB.Template} to "%{_PB.Template}%%arg-4%"
loop (arg-2 parsed as integer) times:
set {_PB.Count} to {PB.Increase} compared to {_PB.Template} / 3
set {PB.Increase} to "%{PB.Increase}%%arg-4%"
loop {_PB.Count}-5 times:
set {PB.Decrease} to "%{PB.Decrease}%%arg-5%"
if arg-1 is "actionbar":
send action bar from "%{PB.Increase}%%{PB.Decrease}%&r" to player
else if arg-1 is "title":
if arg-6 parsed as integer is set:
if arg-7 parsed as integer is set:
if arg-8 parsed as integer is set:
send title from "%{PB.Increase}%%{PB.Decrease}%&r" and "" to player for (arg-7 parsed as integer), (arg-6 parsed as integer), (arg-8 parsed as integer)
else if arg-1 is "subtitle":
if arg-6 parsed as integer is set:
if arg-7 parsed as integer is set:
if arg-8 parsed as integer is set:
send title from "" and "%{PB.Increase}%%{PB.Decrease}%&r" to player for (arg-7 parsed as integer), (arg-6 parsed as integer), (arg-8 parsed as integer)
else if arg-1 is "message":
message "%colored {PB.Increase}%%colored {PB.Decrease}%&r"
else:
message "&a[&1ProcessBar&a] &ccUnknown type. Please type &e/ProcessBar help &cfor help."
exit loop
set {PB.Decrease} to ""
loop arg-3 parsed as integer times:
wait 1 tick
delete {PB.Increase}
delete {PB.Decrease}