Code:
define new bot named "CoinMCBox":
token: "(changed so nobody nukes the dc)"
intents: default intents
policy: all
auto reconnect: true
compression: none
on ready:
set {_linked} to new slash command named "linked" with description "Check for linked people."
add new required user option named "user" with description "The user you want to check!" to options of {_linked}
set {_unlink} to new slash command named "unlink" with description "Unlink a user."
add new required user option named "user" with description "The user you want to unlink!" to options of {_unlink}
set {_link} to new slash command named "link" with description "Link your Discord account to Minecraft!"
add new required string option named "code" with description "Enter the code!" to options of {_link}
on slash command:
set {_name} to event-string
if {_name} = "linked":
event-member has discord permission administrator
set {_arg} to argument "user" as user
if {linkedGeneral::%discord id of {_arg}%::*} is set:
loop indexes of {linkedGeneral::%discord id of {_arg}%::*}:
reply with hidden "The Discord user **%{_arg}%** is linked to the Minecraft account **%loop-value parsed as offlineplayer%** (UUID: **%loop-value%**)"
else:
reply with hidden "The Discord user **%{_arg}%** is not linked to Minecraft."
if {_name} = "unlink":
event-member has discord permission administrator
set {_arg} to argument "user" as user
if {linkedGeneral::%discord id of {_arg}%::*} is set:
loop indexes of {linkedGeneral::%discord id of {_arg}%::*}:
set {_player} to (loop-value parsed as offlineplayer)
delete {linkedGeneral::%discord id of {_arg}%::*}
delete {minecraftLinked::%loop-value%::*}
reply with hidden "The Discord user **%{_arg}%** has been unlinked from the Minecraft account **%{_player}%** (UUID: **%loop-value%**)"
else:
reply with hidden "The Discord user **%{_arg}%** is not linked to Minecraft."
if {_name} = "link":
set {_arg} to argument "code" as string
if {linkedGeneral::%discord id of event-member%::*} is true:
reply with hidden "You have already linked your Discord account to a Minecraft account"
stop
if {code::%{_arg}%} is not set:
reply with hidden "❌ Invalid code"
stop
reply with hidden "✅ You are now linked to %{code::%{_arg}%}%! "
set {minecraftLinked::%{code::%{_arg}%}'s uuid%::%discord id of event-member%} to true
set ({linkedGeneral::%discord id of event-member%::%{code::%{_arg}%}'s uuid%}) to true
make console execute "/crates key give %{code::%{_arg}%}% gear 1"
delete {code::%{_arg}%}
command link:
trigger:
if {minecraftLinked::%uuid of player%::*} is true:
send "&aYou cannot link more than once!" to player
else:
set {_code} to "%random integer between 11111 and 99999%"
set {code::%{_code}%} to player
send "&aYour link code is &b%{_code}%&a. Run the Discord command &b/link %{_code}%&a to link your account. This code will be deleted in &c1&a minute."
wait 1 minute
delete {code::%{_code}%}
command /resetlinking:
permission: command.resetlink
permission message: &cYou cannot perform this command!
trigger:
send "&aRemoved all linked accounts."
set {linkedGeneral::*} to {linkedGeneral::*}
set {minecraftLinked::*} to {minecraftLinked::*}
No skript errors however console has one massive error
Code:
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! [Skript] Severe Error:
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Something went horribly wrong with Skript.
[14:02:26 ERROR]: #!#! This issue is NOT your fault! You probably can't fix it yourself, either.
[14:02:26 ERROR]: #!#! It looks like you are using some plugin(s) that alter how Skript works (addons).
[14:02:26 ERROR]: #!#! Here is full list of them:
[14:02:26 ERROR]: #!#! DiSky v4.7.0 SkBee v3.4.0 (https://github.com/ShaneBeee/SkBee)
[14:02:26 ERROR]: #!#! We could not identify which of those are specially related, so this might also be Skript issue.
[14:02:26 ERROR]: #!#! You should try disabling those plugins one by one, trying to find which one causes it.
[14:02:26 ERROR]: #!#! If the error doesn't disappear even after disabling all listed plugins, it is probably Skript issue.
[14:02:26 ERROR]: #!#! In that case, you will be given instruction on how should you report it.
[14:02:26 ERROR]: #!#! On the other hand, if the error disappears when disabling some plugin, report it to author of that plugin.
[14:02:26 ERROR]: #!#! Only if the author tells you to do so, report it to Skript's issue tracker.
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Stack trace:
[14:02:26 ERROR]: #!#! java.lang.NoSuchFieldError: c
[14:02:26 ERROR]: #!#! at DiSky 4.7.0.jar//info.itsthesky.disky.api.events.DiSkyEvent.init(DiSkyEvent.java:108)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptEvent.init(SkriptEvent.java:80)
[14:02:26 ERROR]: #!#! at Skript (3).jar//org.skriptlang.skript.lang.structure.Structure.init(Structure.java:117)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptParser.parse(SkriptParser.java:264)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptParser.parseStatic(SkriptParser.java:202)
[14:02:26 ERROR]: #!#! at Skript (3).jar//org.skriptlang.skript.lang.structure.Structure.parse(Structure.java:187)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptEvent.parse(SkriptEvent.java:241)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.structures.StructEvent.init(StructEvent.java:57)
[14:02:26 ERROR]: #!#! at Skript (3).jar//org.skriptlang.skript.lang.structure.Structure.init(Structure.java:117)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptParser.parse(SkriptParser.java:264)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.lang.SkriptParser.parseStatic(SkriptParser.java:202)
[14:02:26 ERROR]: #!#! at Skript (3).jar//org.skriptlang.skript.lang.structure.Structure.parse(Structure.java:187)
[14:02:26 ERROR]: #!#! at Skript (3).jar//org.skriptlang.skript.lang.structure.Structure.parse(Structure.java:177)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.loadScript(ScriptLoader.java:654)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.lambda$loadScripts$3(ScriptLoader.java:501)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.lambda$makeFuture$2(ScriptLoader.java:422)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.makeFuture(ScriptLoader.java:438)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.loadScripts(ScriptLoader.java:500)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.ScriptLoader.loadScripts(ScriptLoader.java:457)
[14:02:26 ERROR]: #!#! at Skript (3).jar//ch.njol.skript.SkriptCommand.onCommand(SkriptCommand.java:190)
[14:02:26 ERROR]: #!#! at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45)
[14:02:26 ERROR]: #!#! at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:168)
[14:02:26 ERROR]: #!#! at org.bukkit.craftbukkit.v1_19_R3.CraftServer.dispatchCommand(CraftServer.java:943)
[14:02:26 ERROR]: #!#! at org.bukkit.craftbukkit.v1_19_R3.CraftServer.dispatchServerCommand(CraftServer.java:906)
[14:02:26 ERROR]: #!#! at net.minecraft.server.dedicated.DedicatedServer.bh(DedicatedServer.java:542)
[14:02:26 ERROR]: #!#! at net.minecraft.server.dedicated.DedicatedServer.b(DedicatedServer.java:489)
[14:02:26 ERROR]: #!#! at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:1424)
[14:02:26 ERROR]: #!#! at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:1195)
[14:02:26 ERROR]: #!#! at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:325)
[14:02:26 ERROR]: #!#! at java.base/java.lang.Thread.run(Thread.java:840)
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Version Information:
[14:02:26 ERROR]: #!#! Skript: 2.8.3 (latest)
[14:02:26 ERROR]: #!#! Flavor: skriptlang-github
[14:02:26 ERROR]: #!#! Date: 16:23:04.254419600
[14:02:26 ERROR]: #!#! Bukkit: 1.19.4-R0.1-SNAPSHOT
[14:02:26 ERROR]: #!#! Minecraft: 1.19.4
[14:02:26 ERROR]: #!#! Java: 17.0.10 (OpenJDK 64-Bit Server VM 17.0.10+7)
[14:02:26 ERROR]: #!#! OS: Linux amd64 5.4.0-170-generic
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Server platform: Paper
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Current node: null
[14:02:26 ERROR]: #!#! Current item: null
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Thread: Server thread
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! Language: english
[14:02:26 ERROR]: #!#! Link parse mode: DISABLED
[14:02:26 ERROR]: #!#!
[14:02:26 ERROR]: #!#! End of Error.
[14:02:26 ERROR]: #!#!
I removed skbee and readded it for testing reasons. Error stayed the same even while it was gone. I'm using skript version 2.8.3, Disky version 4.7.0 and skbee version 3.4.0. The server is also a purpur 1.19.4 server. Anyone know the issue?