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/features/impl/FeatureInstaCloseChest.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/features/impl/FeatureInstaCloseChest.java')
-rw-r--r-- | src/main/java/kr/syeyoung/dungeonsguide/features/impl/FeatureInstaCloseChest.java | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/FeatureInstaCloseChest.java b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/FeatureInstaCloseChest.java index 74c0cec3..db2439e5 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/FeatureInstaCloseChest.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/FeatureInstaCloseChest.java @@ -62,10 +62,10 @@ public class FeatureInstaCloseChest extends SimpleFeature implements GuiOpenList public int compare(String o1, String o2) { String id2 = id + "::" + o1 + "-" + enchants.getInteger(o1); AhUtils.AuctionData auctionData = AhUtils.auctions.get(id2); - int price1 = (auctionData == null) ? 0 : ((Integer)auctionData.prices.first()).intValue(); + int price1 = (auctionData == null) ? 0 : auctionData.lowestBin; String id3 = id + "::" + o2 + "-" + enchants.getInteger(o2); AhUtils.AuctionData auctionData2 = AhUtils.auctions.get(id3); - int price2 = (auctionData2 == null) ? 0 : ((Integer)auctionData2.prices.first()).intValue(); + int price2 = (auctionData2 == null) ? 0 : auctionData2.lowestBin; return (compare2(price1, price2) == 0) ? o1.compareTo(o2) : compare2(price1, price2); } @@ -78,7 +78,7 @@ public class FeatureInstaCloseChest extends SimpleFeature implements GuiOpenList for (String key : actualKeys) { String id2 = id + "::" + key + "-" + enchants.getInteger(key); AhUtils.AuctionData auctionData = AhUtils.auctions.get(id2); - totalLowestPrice += auctionData.prices.first(); + totalLowestPrice += auctionData.lowestBin; } return totalLowestPrice; } else { @@ -86,10 +86,10 @@ public class FeatureInstaCloseChest extends SimpleFeature implements GuiOpenList if (auctionData == null) { return 0; } else { - if (auctionData.sellPrice == -1 && auctionData.prices.size() > 0) return auctionData.prices.first(); - else if (auctionData.sellPrice != -1 && auctionData.prices.size() == 0) return auctionData.sellPrice; + if (auctionData.sellPrice == -1 && auctionData.lowestBin != -1) return auctionData.lowestBin; + else if (auctionData.sellPrice != -1 && auctionData.lowestBin == -1) return auctionData.sellPrice; else { - int ahPrice = auctionData.prices.first(); + int ahPrice = auctionData.lowestBin; if (ahPrice > auctionData.sellPrice) return ahPrice; else return auctionData.sellPrice; } |