Skript

Skript

743k Downloads

Skript Error: 'zip file closed' using coordinates

mateusz200156 opened this issue ยท 4 comments

commented

Skript/Server Version

> sk info
[14:38:35 INFO]: [Skript] Skript's aliases can be found here: https://github.com/SkriptLang/skript-aliases
[14:38:35 INFO]: [Skript] Skript's documentation can be found here: https://docs.skriptlang.org/
[14:38:35 INFO]: [Skript] Skript's tutorials can be found here: https://docs.skriptlang.org/tutorials
[14:38:35 INFO]: [Skript] Server Version: 1.21.1-128-d348cb8 (MC: 1.21.1)
[14:38:35 INFO]: [Skript] Skript Version: 2.9.3 (skriptlang-github)
[14:38:35 INFO]: [Skript] Installed Skript Addons: None
[14:38:35 INFO]: [Skript] Installed dependencies: None
>

Bug Description

During the execution of a Skript, an attempt to print player coordinates results in an error message instead of the expected output. While the teleport command successfully teleports the player, the console displays the error: "zip file closed."

Expected Behavior

The /coords command outputs the player's current coordinates to the console or chat, allowing the player to know their exact location.

The /teleportme command teleports the player 5 blocks above their current position, effectively placing them "above their head."

Steps to Reproduce

Using this skript:
command /teleportme:
trigger:
set {_targetLoc} to location of player
add 5 to y-coordinate of {_targetLoc} # Adjusting the Y coordinate
teleport player to {_targetLoc}
send "You have been teleported to your current location, adjusted by 5 blocks up!" to player

command /coords:
trigger:
set {_pos} to player's location
send "Your current coordinates are: %{_pos}%" to the player

Errors or Screenshots

[14:11:03 INFO]: _M4te issued server command: /teleportme
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! [Skript] Severe Error:
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Something went horribly wrong with Skript.
[14:11:03 ERROR]: #!#! This issue is NOT your fault! You probably can't fix it yourself, either.
[14:11:03 ERROR]: #!#! You should report it at https://github.com/SkriptLang/Skript/issues. Please copy paste this report there (or use paste service).
[14:11:03 ERROR]: #!#! This ensures that your issue is noticed and will be fixed as soon as possible.
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Stack trace:
[14:11:03 ERROR]: #!#! java.lang.IllegalStateException: zip file closed
[14:11:03 ERROR]: #!#! at java.base/java.util.zip.ZipFile.ensureOpen(ZipFile.java:846)
[14:11:03 ERROR]: #!#! at java.base/java.util.zip.ZipFile.getEntry(ZipFile.java:338)
[14:11:03 ERROR]: #!#! at java.base/java.util.jar.JarFile.getEntry(JarFile.java:516)
[14:11:03 ERROR]: #!#! at java.base/java.util.jar.JarFile.getJarEntry(JarFile.java:471)
[14:11:03 ERROR]: #!#! at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:209)
[14:11:03 ERROR]: #!#! at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:593)
[14:11:03 ERROR]: #!#! at org.bukkit.plugin.java.PluginClassLoader.loadClass0(PluginClassLoader.java:169)
[14:11:03 ERROR]: #!#! at org.bukkit.plugin.java.PluginClassLoader.loadClass(PluginClassLoader.java:164)
[14:11:03 ERROR]: #!#! at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:526)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//net.kyori.adventure.text.serializer.bungeecord.SelfSerializable$AdapterFactory.create(SelfSerializable.java:58)
[14:11:03 ERROR]: #!#! at com.google.gson.Gson.getAdapter(Gson.java:556)
[14:11:03 ERROR]: #!#! at com.google.gson.Gson.toJson(Gson.java:834)
[14:11:03 ERROR]: #!#! at com.google.gson.Gson.toJson(Gson.java:812)
[14:11:03 ERROR]: #!#! at com.google.gson.Gson.toJson(Gson.java:759)
[14:11:03 ERROR]: #!#! at com.google.gson.Gson.toJson(Gson.java:736)
[14:11:03 ERROR]: #!#! at net.md_5.bungee.chat.ComponentSerializer.toString(ComponentSerializer.java:175)
[14:11:03 ERROR]: #!#! at net.minecraft.network.protocol.game.ClientboundSystemChatPacket.(ClientboundSystemChatPacket.java:18)
[14:11:03 ERROR]: #!#! at org.bukkit.craftbukkit.entity.CraftPlayer$2.sendMessage(CraftPlayer.java:3418)
[14:11:03 ERROR]: #!#! at org.bukkit.craftbukkit.entity.CraftPlayer$2.sendMessage(CraftPlayer.java:3406)
[14:11:03 ERROR]: #!#! at org.bukkit.craftbukkit.entity.CraftPlayer$2.sendMessage(CraftPlayer.java:3386)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.effects.EffMessage.sendMessage(EffMessage.java:154)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.effects.EffMessage.execute(EffMessage.java:128)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.lang.Effect.run(Effect.java:49)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:61)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:88)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.effects.EffTeleport.lambda$walk$0(EffTeleport.java:170)
[14:11:03 ERROR]: #!#! at java.base/java.util.concurrent.CompletableFuture.uniAcceptNow(CompletableFuture.java:757)
[14:11:03 ERROR]: #!#! at java.base/java.util.concurrent.CompletableFuture.uniAcceptStage(CompletableFuture.java:735)
[14:11:03 ERROR]: #!#! at java.base/java.util.concurrent.CompletableFuture.thenAccept(CompletableFuture.java:2214)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.effects.EffTeleport.walk(EffTeleport.java:150)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:88)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.lang.Trigger.execute(Trigger.java:52)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.command.ScriptCommand.execute2(ScriptCommand.java:345)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.command.ScriptCommand.lambda$execute$0(ScriptCommand.java:304)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.command.ScriptCommand.execute(ScriptCommand.java:315)
[14:11:03 ERROR]: #!#! at Skript-2.9.3.jar//ch.njol.skript.command.ScriptCommand.onCommand(ScriptCommand.java:250)
[14:11:03 ERROR]: #!#! at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45)
[14:11:03 ERROR]: #!#! at io.papermc.paper.command.brigadier.bukkit.BukkitCommandNode$BukkitBrigCommand.run(BukkitCommandNode.java:91)
[14:11:03 ERROR]: #!#! at com.mojang.brigadier.context.ContextChain.runExecutable(ContextChain.java:73)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.execution.tasks.ExecuteCommand.execute(ExecuteCommand.java:31)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.execution.tasks.ExecuteCommand.execute(ExecuteCommand.java:19)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.execution.UnboundEntryAction.lambda$bind$0(UnboundEntryAction.java:8)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.execution.CommandQueueEntry.execute(CommandQueueEntry.java:5)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.execution.ExecutionContext.runCommandQueue(ExecutionContext.java:103)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.Commands.executeCommandInContext(Commands.java:443)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.Commands.performCommand(Commands.java:350)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.Commands.performCommand(Commands.java:337)
[14:11:03 ERROR]: #!#! at net.minecraft.commands.Commands.performCommand(Commands.java:332)
[14:11:03 ERROR]: #!#! at net.minecraft.server.network.ServerGamePacketListenerImpl.performUnsignedChatCommand(ServerGamePacketListenerImpl.java:2218)
[14:11:03 ERROR]: #!#! at net.minecraft.server.network.ServerGamePacketListenerImpl.lambda$handleChatCommand$11(ServerGamePacketListenerImpl.java:2192)
[14:11:03 ERROR]: #!#! at net.minecraft.server.TickTask.run(TickTask.java:18)
[14:11:03 ERROR]: #!#! at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:151)
[14:11:03 ERROR]: #!#! at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1535)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:201)
[14:11:03 ERROR]: #!#! at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:125)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1512)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1505)
[14:11:03 ERROR]: #!#! at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:135)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.managedBlock(MinecraftServer.java:1464)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1471)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1316)
[14:11:03 ERROR]: #!#! at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:329)
[14:11:03 ERROR]: #!#! at java.base/java.lang.Thread.run(Thread.java:1583)
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Version Information:
[14:11:03 ERROR]: #!#! Skript: 2.9.3 (latest)
[14:11:03 ERROR]: #!#! Flavor: skriptlang-github
[14:11:03 ERROR]: #!#! Date: 18:47:10.127605400
[14:11:03 ERROR]: #!#! Bukkit: 1.21.1-R0.1-SNAPSHOT
[14:11:03 ERROR]: #!#! Minecraft: 1.21.1
[14:11:03 ERROR]: #!#! Java: 21.0.4 (Java HotSpot(TM) 64-Bit Server VM 21.0.4+8-LTS-274)
[14:11:03 ERROR]: #!#! OS: Windows 11 amd64 10.0
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Server platform: Paper
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Current node: null
[14:11:03 ERROR]: #!#! Current item: send "You have been teleported to your current location, adjusted by 5 blocks up!" to the player
[14:11:03 ERROR]: #!#! Current trigger: command /teleportme (simple event) (location.sk, line 2)
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Thread: Server thread
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! Language: english
[14:11:03 ERROR]: #!#! Link parse mode: DISABLED
[14:11:03 ERROR]: #!#!
[14:11:03 ERROR]: #!#! End of Error.
[14:11:03 ERROR]: #!#!

Other

No response

Agreement

  • I have read the guidelines above and affirm I am following them with this report.
commented

Have you used the /reload command?

commented

this is not a skript issue, close and then start your server again (other examples of this happening: https://github.com/SkriptLang/Skript/issues?q=is%3Aissue+zip+file+is%3Aclosed)

commented

Yes, I used the /reload command, but it still didn't work properly afterwards. I also tried restarting the entire server, and the result was the same.

commented

Thanks Efnilite ,but dos not work.
After I restarted my pc and run again a server it was work