Skip to content
This repository has been archived by the owner on May 2, 2023. It is now read-only.

Commit

Permalink
Support the souls stat of SkyWars.
Browse files Browse the repository at this point in the history
  • Loading branch information
SNWCreations committed Aug 19, 2022
1 parent ab3ca64 commit f8818e7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/java/snw/hypixelbot/commands/SwCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ public void onCommand(User sender, String[] arguments, Message message) {

String name = player.getName();
JsonObject swStat = player.getRaw().getAsJsonObject("stats").getAsJsonObject("SkyWars");
int souls = swStat.get("souls").getAsInt();
int coins = swStat.get("coins").getAsInt();
int fails = swStat.get("losses").getAsInt();
int winstreak = swStat.get("win_streak").getAsInt();
Expand All @@ -51,11 +52,12 @@ public void onCommand(User sender, String[] arguments, Message message) {
new PlainTextElement(
String.format(
"硬币: %s\n" +
"灵魂: %s\n" +
"当前连胜: %s\n" +
"方块放置数: %s\n" +
"失败: %s\n" +
"死亡: %s",
coins, winstreak, blocks_placed, fails, deaths
coins, souls, winstreak, blocks_placed, fails, deaths
), false
), null, null
)
Expand Down

0 comments on commit f8818e7

Please sign in to comment.