Removed Missing Coin application functionality from CustomerSupport server.

This commit is contained in:
Jonathan Williams 2015-03-25 15:05:06 -07:00
parent 09fe3ad6a8
commit 294041b821

View File

@ -103,9 +103,7 @@ public class CustomerSupport extends MiniPlugin
caller.sendMessage(C.cBlue + "Coins : " + C.cYellow + donor.getCoins());
caller.sendMessage(C.cBlue + "Gems : " + C.cYellow + donor.GetGems());
int coinTransactionTotal = 0;
int enjinCoinsReceived = 0;
int coinSpentTotal = 0;
int oldChestsReceived = 0;
int ancientChestsReceived = 0;
int mythicalChestsReceived = 0;
@ -114,8 +112,6 @@ public class CustomerSupport extends MiniPlugin
{
if (transaction.Source.equalsIgnoreCase("Poll") || transaction.Source.equalsIgnoreCase("Halloween Pumpkin") || transaction.Source.equalsIgnoreCase("Treasure Chest") || transaction.Source.equalsIgnoreCase("Coin Party Bomb Pickup") || transaction.Source.contains("Reward") || transaction.Source.contains("purchase"))
{
coinTransactionTotal += transaction.Amount;
if (transaction.Source.contains("purchase"))
enjinCoinsReceived += transaction.Amount;
}
@ -123,8 +119,6 @@ public class CustomerSupport extends MiniPlugin
for (TransactionToken transaction : donor.getTransactions())
{
coinSpentTotal += transaction.Coins;
if (transaction.SalesPackageName.startsWith("Old Chest"))
{
if (transaction.Coins == 0 && transaction.Gems == 0)
@ -165,15 +159,6 @@ public class CustomerSupport extends MiniPlugin
caller.sendMessage(C.cBlue + "Ancient Chests Received : " + C.cYellow + ancientChestsReceived);
caller.sendMessage(C.cBlue + "Mythical Chests Received : " + C.cYellow + mythicalChestsReceived);
int coinsMissing = coinTransactionTotal - (donor.getCoins() + coinSpentTotal);
if (coinsMissing > 0)
{
caller.sendMessage(C.cRed + "Coins missing!");
new JsonMessage("[").color("blue").extra(C.cGreen + "Apply Missing Coins").color("green").click("run_command", "/sales coin " + playerName + " " + coinsMissing)
.add("] ").color("blue").add("Missing Coins.").color("yellow").sendToPlayer(caller);
}
caller.sendMessage(C.cDGreen + C.Strike + "=============================================");
_salesPackageManager.displaySalesPackages(caller, playerName);
caller.sendMessage(C.cDGreen + C.Strike + "=============================================");