Atum 2: Return to the Sands

Atum 2: Return to the Sands

22M Downloads

Missing command usage text and perform success text for /atumweather command

mc-kaishixiaxue opened this issue ยท 3 comments

commented

Atum version: 2.0.6

When a player entered /atumweather command without any parameter, this is a wrong usage, the game showed a red text: An unknown error occurred while attempting to perform this command

/atumweather clear, /atumweather storm and /atumweather sandstorm are all correct commands, I cannot see the command success text after entering them, but the weather in Atum was changed successfully.

/atumweather command's java file: https://github.com/TeamMetallurgy/Atum2/blob/master/src/main/java/com/teammetallurgy/atum/commands/AtumWeather.java

I found some texts on the game log:

[14:43:18] [Server thread/WARN] [minecraft/CommandHandler]: Couldn't process command: atumweather
java.lang.ArrayIndexOutOfBoundsException: 0
at com.teammetallurgy.atum.commands.AtumWeather.execute(AtumWeather.java:41) ~[AtumWeather.class:?]
at net.minecraft.command.CommandHandler.tryExecute(CommandHandler.java:119) [bj.class:?]
at net.minecraft.command.CommandHandler.executeCommand(CommandHandler.java:91) [bj.class:?]
at net.minecraft.network.NetHandlerPlayServer.handleSlashCommand(NetHandlerPlayServer.java:962) [pa.class:?]
at net.minecraft.network.NetHandlerPlayServer.processChatMessage(NetHandlerPlayServer.java:941) [pa.class:?]
at net.minecraft.network.play.client.CPacketChatMessage.processPacket(SourceFile:37) [la.class:?]
at net.minecraft.network.play.client.CPacketChatMessage.processPacket(SourceFile:9) [la.class:?]
at net.minecraft.network.PacketThreadUtil$1.run(PacketThreadUtil.java:22) [hv$1.class:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_211]
at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_211]
at net.minecraft.util.Util.runTask(Util.java:529) [h.class:?]
at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:723) [MinecraftServer.class:?]
at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:668) [MinecraftServer.class:?]
at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:256) [chd.class:?]
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) [MinecraftServer.class:?]
at java.lang.Thread.run(Unknown Source) [?:1.8.0_211]

commented

Please let me update zh_cn

commented

You're very welcome, just make a PR :)

commented

My PR has been created.
#108