mirror of
https://github.com/Crazy-Crew/CrazyAuctions.git
synced 2024-11-26 12:35:44 +01:00
Changed placeholders to lowercase
This commit is contained in:
parent
b4b12e6e99
commit
286c4eb752
@ -149,6 +149,7 @@ public class Main extends JavaPlugin implements Listener {
|
||||
if(!Methods.isInt(args[2])) {
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Arg%", args[2]);
|
||||
placeholders.put("%arg%", args[2]);
|
||||
player.sendMessage(Messages.NOT_A_NUMBER.getMessage(placeholders));
|
||||
return true;
|
||||
}
|
||||
@ -159,6 +160,7 @@ public class Main extends JavaPlugin implements Listener {
|
||||
if(!Methods.isLong(args[1])) {
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Arg%", args[1]);
|
||||
placeholders.put("%arg%", args[1]);
|
||||
player.sendMessage(Messages.NOT_A_NUMBER.getMessage(placeholders));
|
||||
return true;
|
||||
}
|
||||
@ -287,6 +289,7 @@ public class Main extends JavaPlugin implements Listener {
|
||||
Bukkit.getPluginManager().callEvent(new AuctionListEvent(player, type, I, price));
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Price%", price + "");
|
||||
placeholders.put("%price%", price + "");
|
||||
player.sendMessage(Messages.ADDED_ITEM_TO_AUCTION.getMessage(placeholders));
|
||||
if(item.getAmount() <= 1 || (item.getAmount() - amount) <= 0) {
|
||||
Methods.setItemInHand(player, new ItemStack(Material.AIR));
|
||||
|
@ -382,7 +382,9 @@ public class Methods {
|
||||
CurrencyManager.removeMoney(Methods.getOfflinePlayer(winner), price);
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Price%", getPrice(i, false));
|
||||
placeholders.put("%price%", getPrice(i, false));
|
||||
placeholders.put("%Player%", winner);
|
||||
placeholders.put("%player%", winner);
|
||||
if(Methods.isOnline(winner)) {
|
||||
Player player = Methods.getPlayer(winner);
|
||||
Bukkit.getPluginManager().callEvent(new AuctionWinBidEvent(player, data.getItemStack("Items." + i + ".Item"), price));
|
||||
|
@ -12,12 +12,12 @@ public enum Messages {
|
||||
|
||||
PLAYERS_ONLY("Players-Only", "&cOnly players can use this command."),
|
||||
RELOAD("Reload", "&7You have just reloaded the Crazy Auctions Files."),
|
||||
NEED_MORE_MONEY("Need-More-Money", "&cYou are in need of &a$%Money_Needed%&c."),
|
||||
NEED_MORE_MONEY("Need-More-Money", "&cYou are in need of &a$%money_needed%&c."),
|
||||
INVENTORY_FULL("Inventory-Full", "&cYour inventory is too full. Please open up some space to buy that."),
|
||||
NO_PERMISSION("No-Permission", "&cYou do not have permission to use that command!"),
|
||||
NOT_ONLINE("Not-Online", "&cThat player is not online at this time."),
|
||||
DOSENT_HAVE_ITEM_IN_HAND("Doesnt-Have-Item-In-Hand", "&cYou must have an item in your hand."),
|
||||
NOT_A_NUMBER("Not-A-Number", "&c%Arg% is not a number."),
|
||||
NOT_A_NUMBER("Not-A-Number", "&c%arg% is not a number."),
|
||||
GOT_ITEM_BACK("Got-Item-Back", "&7Your item has been returned."),
|
||||
CANCELLED_ITEM("Cancelled-Item", "&7You have cancelled an item on the auction list, return your items with /ah expired."),
|
||||
ITEM_HAS_EXPIRED("Item-Has-Expired", "&7An item you have in the Crazy Auctions has just expired."),
|
||||
@ -34,11 +34,11 @@ public enum Messages {
|
||||
SELL_PRICE_TO_HIGH("Sell-Price-To-High", "&cYour sell price is to high the maximum is &a$1000000&c."),
|
||||
BID_PRICE_TO_LOW("Bid-Price-To-Low", "&cYour starting bid price is to low the minimum is &a$100&c."),
|
||||
BID_PRICE_TO_HIGH("Bid-Price-To-High", "&cYour starting bid price is to high the maximum is &a$1000000&c."),
|
||||
BOUGHT_ITEM("Bought-Item", "&7You have just bought a item for &a$%Price%&7."),
|
||||
WIN_BIDDING("Win-Bidding", "&7You have just won a bid for &a$%Price%&7. Do /Ah Collect to collect your winnings."),
|
||||
PLAYER_BOUGHT_ITEM("Player-Bought-Item", "&7%Player% has bought your item for &a$%Price%."),
|
||||
SOMEONE_WON_PLAYERS_BID("Someone-Won-Players-Bid", "&7%Player% has won your item you from a bid for &a$%Price%."),
|
||||
ADDED_ITEM_TO_AUCTION("Added-Item-To-Auction", "&7You have just added a item to the crazy auctions for &a$%Price%&7."),
|
||||
BOUGHT_ITEM("Bought-Item", "&7You have just bought a item for &a$%price%&7."),
|
||||
WIN_BIDDING("Win-Bidding", "&7You have just won a bid for &a$%price%&7. Do /Ah Collect to collect your winnings."),
|
||||
PLAYER_BOUGHT_ITEM("Player-Bought-Item", "&7%player% has bought your item for &a$%price%."),
|
||||
SOMEONE_WON_PLAYERS_BID("Someone-Won-Players-Bid", "&7%player% has won your item you from a bid for &a$%price%."),
|
||||
ADDED_ITEM_TO_AUCTION("Added-Item-To-Auction", "&7You have just added a item to the crazy auctions for &a$%price%&7."),
|
||||
BID_MESSAGE("Bid-Msg", "&7You have just bid &a$%Bid% &7on that item."),
|
||||
SELLING_DISABLED("Selling-Disabled", "&cThe selling option is disabled."),
|
||||
BIDDING_DISABLED("Bidding-Disabled", "&cThe bidding option is disabled."),
|
||||
|
@ -494,6 +494,7 @@ public class GUI implements Listener {
|
||||
if(CurrencyManager.getMoney(player) < bid) {
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Money_Needed%", (bid - CurrencyManager.getMoney(player)) + "");
|
||||
placeholders.put("%money_needed%", (bid - CurrencyManager.getMoney(player)) + "");
|
||||
player.sendMessage(Messages.NEED_MORE_MONEY.getMessage(placeholders));
|
||||
return;
|
||||
}
|
||||
@ -741,6 +742,7 @@ public class GUI implements Listener {
|
||||
player.closeInventory();
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Money_Needed%", (cost - CurrencyManager.getMoney(player)) + "");
|
||||
placeholders.put("%money_needed%", (cost - CurrencyManager.getMoney(player)) + "");
|
||||
player.sendMessage(Messages.NEED_MORE_MONEY.getMessage(placeholders));
|
||||
return;
|
||||
}
|
||||
@ -750,7 +752,9 @@ public class GUI implements Listener {
|
||||
CurrencyManager.addMoney(Methods.getOfflinePlayer(seller), cost);
|
||||
HashMap<String, String> placeholders = new HashMap<>();
|
||||
placeholders.put("%Price%", Methods.getPrice(ID, false));
|
||||
placeholders.put("%price%", Methods.getPrice(ID, false));
|
||||
placeholders.put("%Player%", player.getName());
|
||||
placeholders.put("%player%", player.getName());
|
||||
player.sendMessage(Messages.BOUGHT_ITEM.getMessage(placeholders));
|
||||
if(Methods.isOnline(seller)) {
|
||||
Player sell = Methods.getPlayer(seller);
|
||||
|
@ -1,12 +1,12 @@
|
||||
Messages:
|
||||
Players-Only: '&cOnly players can use this command.'
|
||||
Reload: '&7You have just reloaded the Crazy Auctions Files.'
|
||||
Need-More-Money: '&cYou are in need of &a$%Money_Needed%&c.'
|
||||
Need-More-Money: '&cYou are in need of &a$%money_needed%&c.'
|
||||
Inventory-Full: '&cYour inventory is too full. Please open up some space to buy that.'
|
||||
No-Permission: '&cYou do not have permission to use that command!'
|
||||
Not-Online: '&cThat player is not online at this time.'
|
||||
Doesnt-Have-Item-In-Hand: '&cYou must have an item in your hand.'
|
||||
Not-A-Number: '&c%Arg% is not a number.'
|
||||
Not-A-Number: '&c%arg% is not a number.'
|
||||
Got-Item-Back: '&7Your item has been returned.'
|
||||
Cancelled-Item: '&7You have canceled an item on the auction list, return your items with /ah expired.'
|
||||
Item-Has-Expired: '&7An item you have in the Crazy Auctions has just expired.'
|
||||
@ -23,11 +23,11 @@ Messages:
|
||||
Sell-Price-To-High: '&cYour sell price is too high the maximum is &a$1000000&c.'
|
||||
Bid-Price-To-Low: '&cYour starting bid price is to low the minimum is &a$100&c.'
|
||||
Bid-Price-To-High: '&cYour starting bid price is too high the maximum is &a$1000000&c.'
|
||||
Bought-Item: '&7You have just bought an item for &a$%Price%&7.'
|
||||
Win-Bidding: '&7You have just won a bid for &a$%Price%&7. Do /Ah Collect to collect your winnings.'
|
||||
Player-Bought-Item: '&7%Player% has bought your item for &a$%Price%.'
|
||||
Someone-Won-Players-Bid: '&7%Player% has won your item you from a bid for &a$%Price%.'
|
||||
Added-Item-To-Auction: '&7You have just added an item to the crazy auctions for &a$%Price%&7.'
|
||||
Bought-Item: '&7You have just bought an item for &a$%price%&7.'
|
||||
Win-Bidding: '&7You have just won a bid for &a$%price%&7. Do /Ah Collect to collect your winnings.'
|
||||
Player-Bought-Item: '&7%player% has bought your item for &a$%price%.'
|
||||
Someone-Won-Players-Bid: '&7%player% has won your item you from a bid for &a$%price%.'
|
||||
Added-Item-To-Auction: '&7You have just added an item to the crazy auctions for &a$%price%&7.'
|
||||
Bid-Msg: '&7You have just bid &a$%Bid% &7on that item.'
|
||||
Selling-Disabled: '&cThe selling option is disabled.'
|
||||
Bidding-Disabled: '&cThe bidding option is disabled.'
|
||||
|
Loading…
Reference in New Issue
Block a user