Skript Version (do not put latest): Skript 2.2 (dev36)
Skript Author: Bensku
Minecraft Version: 1.8.8
---
Full Code:
Addons using (including versions):
SkRayFall 1.9.10, skUtilities 0.9.2, Vixio 1.1.5
Troubleshooting:
Have you tried searching the docs? Yes
Have you tried searching the forums? No
What other methods have you tried to fix it? I have attempted to reorganize and use different methods such as math (minusing one variable from another then seeing if the outcome is above or below zero) but to no avail to get all 3 working.
Skript Author: Bensku
Minecraft Version: 1.8.8
---
Full Code:
code_language.skript:
function updateCheckerCmd(p: player):
set {dversion} to "2.1" #parsed as a number
set {_dv} to line 1 from url "https://api.spigotmc.org/legacy/update.php?resource=25750/"
# set {_dv} to "%{_dver::1}%" #parsed as a number
set {dversion} to {dversion} parsed as a number
set {_dv} to {_dv} parsed as a number
wait 1 tick
broadcast "%{_dv}%"
if {dversion} > {_dv}:
send "&8[&9&lDISCORD&8] &7Either you're running a beta version or you changed the version number! (&8v&a%{dversion}%&7)" to {_p}
else if {_dv} = {dversion}:
send "&8[&9&lDISCORD&8] &7You are currently running the latest version of &a&lDiscord &8v&a%{dversion}%&7." to {_p}
else if {dversion} < {_dv}:
send "&8[&9&lDISCORD&8] &7An update is available! (&a%{dversion}% &7-> &a%{_dv}%&7)" to {_p}
send "&8[&9&lDISCORD&8] &7Download it here: &fhttp://bit.ly/2wsW3IB" to {_p}
else:
send "no" to {_p}
Addons using (including versions):
SkRayFall 1.9.10, skUtilities 0.9.2, Vixio 1.1.5
Troubleshooting:
Have you tried searching the docs? Yes
Have you tried searching the forums? No
What other methods have you tried to fix it? I have attempted to reorganize and use different methods such as math (minusing one variable from another then seeing if the outcome is above or below zero) but to no avail to get all 3 working.