Solved Issue with reloading a skript

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the community!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

cheatchki

Supporter ++
Jun 26, 2017
49
1
8
So I am trying to make a beautiful skript where you can plug in addons later on, all is great! however I have these functions built in
This would be the main core file
code_language.skript:
command /s [<text>] [<text>] [<text>]:
    trigger:
        if arg 1 is "versions":
            message "Core: {@version}"
            message "%research_get_version()%"
            message "%weapons_get_version()%"
then i have
code_language.skript:
function research_get_version() :: text:
    return "research: {@version}"
along with the weapons function same premises as research just on different file


When I start up something goes wrong with these and I have to disable the core, reload the research function, get it to work, then re-enable the core.
Once I get it working all nicely, if I reload the research or weapons file, they wont properly load up and this error is thrown at me
10:38:09 AM

Cheatchki issued server command: /skript reload research
10:38:09 AM [SEVERE] #!#!
10:38:09 AM [SEVERE] #!#! [Skript] Severe Error:
10:38:09 AM [SEVERE] #!#! Exception occurred in Skript's main command
10:38:09 AM [SEVERE] #!#! Used command: /skript reload research
10:38:09 AM [SEVERE] #!#!
10:38:09 AM [SEVERE] #!#! Something went horribly wrong with Skript.
10:38:09 AM [SEVERE] #!#! This issue is NOT your fault! You can't probably fix it yourself, either.
10:38:09 AM [SEVERE] #!#! It looks like you are using some plugin(s) that alter how Skript works (addons).
10:38:09 AM [SEVERE] #!#! Here is full list of them:
10:38:09 AM [SEVERE] #!#! skRayFall (http://sk.rayfall.net/) skDragon SkQuery Skellett (https://forums.skunity.com/resources/skellett-the-addon-with-a-beast-name.24/) Umbaska SharpSK TuSKe (github.com/Tuke-Nuke/TuSKe)
10:38:09 AM [SEVERE] #!#! We could not identify which of those are specially related, so this might also be Skript issue.
10:38:09 AM [SEVERE] #!#! You should try disabling those plugins one by one, trying to find which one causes it.
10:38:09 AM [SEVERE] #!#! If the error doesn't disappear even after disabling all listed plugins, it is probably Skript issue.
10:38:09 AM [SEVERE] #!#! In that case, you will be given instruction on how should you report it.
10:38:09 AM [SEVERE] #!#! On the other hand, if the error disappears when disabling some plugin, report it to author of that plugin.
10:38:09 AM [SEVERE] #!#! Only if the author tells you to do so, report it as Skript issue (url below)
10:38:09 AM [SEVERE] #!#! Issue tracker: https://github.com/bensku/Skript/issues (only if you know what you're doing!)
10:38:09 AM [SEVERE] #!#!
10:38:09 AM [SEVERE] #!#! Stack trace:
10:38:09 AM [SEVERE] #!#! java.lang.NullPointerException
10:38:09 AM [SEVERE] #!#! at ch.njol.skript.lang.function.Functions.registerCaller(Functions.java:96)
10:38:09 AM [SEVERE] #!#! at ch.njol.skript.lang.function.FunctionReference.validateFunction(FunctionReference.java:167)
10:38:09 AM [SEVERE] #!#! at ch.njol.skript.lang.function.Functions.validateFunctions(Functions.java:302)
10:38:09 AM [SEVERE] #!#! at ch.njol.skript.ScriptLoader.unloadScript(ScriptLoader.java:790)
10:38:09 AM [SEVERE] #!#! at ch.njol.skript.SkriptCommand.onCommand(SkriptCommand.java:186)
10:38:09 AM [SEVERE] #!#! at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
10:38:09 AM [SEVERE] #!#! at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:141)
10:38:09 AM [SEVERE] #!#! at org.bukkit.craftbukkit.v1_12_R1.CraftServer.dispatchCommand(CraftServer.java:647)
10:38:09 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.PlayerConnection.handleCommand(PlayerConnection.java:1386)
10:38:09 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.PlayerConnection.a(PlayerConnection.java:1221)
10:38:09 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.PacketPlayInChat.a(PacketPlayInChat.java:45)
10:38:09 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.PacketPlayInChat.a(PacketPlayInChat.java:1)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.PlayerConnectionUtils$1.run(SourceFile:13)
10:38:10 AM [SEVERE] #!#! at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
10:38:10 AM [SEVERE] #!#! at java.util.concurrent.FutureTask.run(Unknown Source)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.SystemUtils.a(SourceFile:46)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.MinecraftServer.D(MinecraftServer.java:748)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.DedicatedServer.D(DedicatedServer.java:406)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.MinecraftServer.C(MinecraftServer.java:679)
10:38:10 AM [SEVERE] #!#! at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:577)
10:38:10 AM [SEVERE] #!#! at java.lang.Thread.run(Unknown Source)
10:38:10 AM [SEVERE] #!#!
10:38:10 AM [SEVERE] #!#! Version Information:
10:38:10 AM [SEVERE] #!#! Skript: 2.2-dev30d (latest)
10:38:10 AM [SEVERE] #!#! Bukkit: 1.12.1-R0.1-SNAPSHOT
10:38:10 AM [SEVERE] #!#! Minecraft: 1.12.1
10:38:10 AM [SEVERE] #!#! Java: 1.8.0_131 (Java HotSpot(TM) 64-Bit Server VM 25.131-b11)
10:38:10 AM [SEVERE] #!#! OS: Windows 7 amd64 6.1
10:38:10 AM [SEVERE] #!#!
10:38:10 AM [SEVERE] #!#! Running CraftBukkit: false
10:38:10 AM [SEVERE] #!#! Running Spigot (or compatible): true
10:38:10 AM [SEVERE] #!#! Running Paper (or compatible): false
10:38:10 AM [SEVERE] #!#!
10:38:10 AM [SEVERE] #!#! Current node: message "%research_get_version()%" (core.sk, line 19)
10:38:10 AM [SEVERE] #!#! Current item: null
10:38:10 AM [SEVERE] #!#! Thread: Server thread
10:38:10 AM [SEVERE] #!#!
10:38:10 AM [SEVERE] #!#! Language: english
10:38:10 AM [SEVERE] #!#! Link parse mode: DISABLED
10:38:10 AM [SEVERE] #!#!
10:38:10 AM [SEVERE] #!#! End of Error.
10:38:10 AM [SEVERE] #!#!



I did find that removing functions involved in other files does work, but if I am going to do add-ons then I almost certainly will need functions running across files.

 
So I am trying to make a beautiful skript where you can plug in addons later on, all is great! however I have these functions built in
This would be the main core file
code_language.skript:
command /s [<text>] [<text>] [<text>]:
    trigger:
        if arg 1 is "versions":
            message "Core: {@version}"
            message "%research_get_version()%"
            message "%weapons_get_version()%"
then i have
code_language.skript:
function research_get_version() :: text:
    return "research: {@version}"
along with the weapons function same premises as research just on different file


When I start up something goes wrong with these and I have to disable the core, reload the research function, get it to work, then re-enable the core.
Once I get it working all nicely, if I reload the research or weapons file, they wont properly load up and this error is thrown at me


I did find that removing functions involved in other files does work, but if I am going to do add-ons then I almost certainly will need functions running across files.
I got that error a lot on 30d, it's just not a stable build yet. troubleshooting it myself by removing addons and putting them back one by one it seemed to be tuske and skquery that gave me that reload error. I just went back to dev 29 to solve it.
I would do the same for your addons, try disabling them all like the error says and see if the problem addon is one you can do without. Elsewise you may need to go back to dev 29 for a bit too until 30 is more stable.
 
Status
Not open for further replies.