From e1b2f7391c260d3e8e61ea636edc4f3cb4d5fea5 Mon Sep 17 00:00:00 2001 From: Thijs Wiefferink Date: Thu, 2 Feb 2017 16:45:06 +0100 Subject: [PATCH] Improve message when you cannot rent/buy a region The message did not specify which region cannot be rented/bought, which has now been added. --- .../java/me/wiefferink/areashop/commands/BuyCommand.java | 2 +- .../java/me/wiefferink/areashop/commands/RentCommand.java | 2 +- AreaShop/src/main/resources/lang/EN.yml | 6 +++--- pom.xml | 4 ++++ 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/AreaShop/src/main/java/me/wiefferink/areashop/commands/BuyCommand.java b/AreaShop/src/main/java/me/wiefferink/areashop/commands/BuyCommand.java index 4688268..ef5bc4b 100644 --- a/AreaShop/src/main/java/me/wiefferink/areashop/commands/BuyCommand.java +++ b/AreaShop/src/main/java/me/wiefferink/areashop/commands/BuyCommand.java @@ -42,7 +42,7 @@ public class BuyCommand extends CommandAreaShop { if(args.length > 1 && args[1] != null) { BuyRegion region = plugin.getFileManager().getBuy(args[1]); if(region == null) { - plugin.message(player, "buy-notBuyable"); + plugin.message(player, "buy-notBuyable", args[1]); } else { region.buy(player); } diff --git a/AreaShop/src/main/java/me/wiefferink/areashop/commands/RentCommand.java b/AreaShop/src/main/java/me/wiefferink/areashop/commands/RentCommand.java index 7ce4737..21b1564 100644 --- a/AreaShop/src/main/java/me/wiefferink/areashop/commands/RentCommand.java +++ b/AreaShop/src/main/java/me/wiefferink/areashop/commands/RentCommand.java @@ -42,7 +42,7 @@ public class RentCommand extends CommandAreaShop { if(args.length > 1 && args[1] != null) { RentRegion rent = plugin.getFileManager().getRent(args[1]); if(rent == null) { - plugin.message(sender, "rent-notRentable"); + plugin.message(sender, "rent-notRentable", args[1]); } else { rent.rent(player); } diff --git a/AreaShop/src/main/resources/lang/EN.yml b/AreaShop/src/main/resources/lang/EN.yml index 94f93f5..d9359c3 100644 --- a/AreaShop/src/main/resources/lang/EN.yml +++ b/AreaShop/src/main/resources/lang/EN.yml @@ -110,7 +110,7 @@ rent-extendedToMax: "You extended your rent of %lang:region% until %until% (whic rent-lowMoneyExtend: "You don't have enough money to extend the rent (you have %0% and you need %price%)." rent-lowMoneyRent: "You don't have enough money to rent %lang:region% (you have %0% and you need %price%)." rent-someoneElse: "Someone else already rented %lang:region%." -rent-notRentable: "That region is not available for renting." +rent-notRentable: "Region '%0%' is not available for renting (not registered in AreaShop or it is a buy region)." rent-maxExtends: "You cannot extend this rent anymore (the maximum is %maxextends% times), however after the rent is over you can rent %lang:region% again." rent-maxRentTime: "You cannot rent %lang:region% more time in advance, the maximum time is %maxrenttime% and you have currently rented it for %timeleft%." rent-restrictedToWorld: "You need to be in the '%world%' world to rent %lang:region% (you are in '%0%')." @@ -123,7 +123,7 @@ buy-help: "/as buy [region], the region you stand in will be used if not specifi buy-noPermission: "You don't have permission to buy a region." buy-noPermissionResell: "You don't have permission to buy a region in resell mode." buy-noPermissionNoResell: "You don't have permission to buy a region that is not in resell mode." -buy-notBuyable: "Region %lang:region% is not available for buying." +buy-notBuyable: "Region '%0%' is not available for buying (not registered in AreaShop or it is a rental region)." buy-maximum: "You can't buy more than %0% region(s) (you already have %1% in group '%2%')." buy-payError: "Something went wrong with paying, try again later." buy-succes: "You successfully bought %lang:region%." @@ -151,7 +151,7 @@ sell-sold: "%lang:region% of %lang:player% has been sold." sell-noPermission: "You don't have permission to sell a region." sell-noPermissionOther: "You don't have permission to sell another region." -reload-reloading: "Reloaded all files, now checking rents and updating regions." +reload-reloading: "Reloaded all configuration and region files." reload-updateStart: "[gray]Updating %0% regions at %1% per second." reload-updateComplete: "[gray]Updating regions complete." reload-noPermission: "You don't have permission to reload the config files." diff --git a/pom.xml b/pom.xml index 6c60ccc..36ffac3 100644 --- a/pom.xml +++ b/pom.xml @@ -21,6 +21,10 @@ vault-repo http://nexus.hc.to/content/repositories/pub_releases + + wiefferink-repo + http://jenkins.wiefferink.me/plugin/repository/everything/ +