diff options
author | syeyoung <cyong06@naver.com> | 2021-01-09 14:00:44 +0900 |
---|---|---|
committer | syeyoung <cyong06@naver.com> | 2021-01-09 14:00:44 +0900 |
commit | 3513364b2177cb88c57284c113b367000e93f2e5 (patch) | |
tree | dcfc0401cada0bfe319422fa3fe1c61493498777 /src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java | |
parent | b382461db0b5fb96271bf548fa5aa89f0981ae05 (diff) | |
download | Skyblock-Dungeons-Guide-3513364b2177cb88c57284c113b367000e93f2e5.tar.gz Skyblock-Dungeons-Guide-3513364b2177cb88c57284c113b367000e93f2e5.tar.bz2 Skyblock-Dungeons-Guide-3513364b2177cb88c57284c113b367000e93f2e5.zip |
what?
Diffstat (limited to 'src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java')
-rw-r--r-- | src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java b/src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java index 1fa740ce..5273bbe4 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/commands/CommandDungeonsGuide.java @@ -3,6 +3,7 @@ package kr.syeyoung.dungeonsguide.commands; import kr.syeyoung.dungeonsguide.config.guiconfig.GuiConfig; import kr.syeyoung.dungeonsguide.dungeon.roomfinder.DungeonRoomInfoRegistry; import kr.syeyoung.dungeonsguide.e; +import kr.syeyoung.dungeonsguide.utils.AhUtils; import net.minecraft.client.Minecraft; import net.minecraft.command.CommandBase; import net.minecraft.command.ICommandSender; @@ -14,9 +15,8 @@ import javax.crypto.BadPaddingException; import javax.crypto.IllegalBlockSizeException; import javax.crypto.NoSuchPaddingException; import java.io.IOException; -import java.security.InvalidAlgorithmParameterException; -import java.security.InvalidKeyException; -import java.security.NoSuchAlgorithmException; +import java.security.*; +import java.security.cert.CertificateException; public class CommandDungeonsGuide extends CommandBase { @Override @@ -58,12 +58,36 @@ public class CommandDungeonsGuide extends CommandBase { e.printStackTrace(); } sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §cAn error has occurred while loading roomdata")); + } else if (args[0].equalsIgnoreCase("reloadah")) { + try { + AhUtils.loadAuctions(); + } catch (CertificateException e) { + e.printStackTrace(); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } catch (InvalidKeyException e) { + e.printStackTrace(); + } catch (InvalidAlgorithmParameterException e) { + e.printStackTrace(); + } catch (NoSuchPaddingException e) { + e.printStackTrace(); + } catch (BadPaddingException e) { + e.printStackTrace(); + } catch (KeyStoreException e) { + e.printStackTrace(); + } catch (IllegalBlockSizeException e) { + e.printStackTrace(); + } catch (KeyManagementException e) { + e.printStackTrace(); + } + sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §fReloaded Ah data")); } else { sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg §7-§fOpens configuration gui")); sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg gui §7-§fOpens configuration gui")); sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg help §7-§fShows command help")); sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg saverooms §7-§f Saves usergenerated dungeon roomdata.")); sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg loadrooms §7-§f Reloads dungeon roomdata.")); + sender.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §e/dg reloadah §7-§f Reloads price data from server.")); } } |