Skip to content

Commit

Permalink
- Remove /town unclaim outpost from /town unclaim ?
Browse files Browse the repository at this point in the history
  - Add /ta unclaim & /plot unclaim tab completes.
    - Closes #3883.
  • Loading branch information
LlmDl committed Apr 9, 2020
1 parent 92b0c0d commit 7cccef6
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
5 changes: 4 additions & 1 deletion resources/ChangeLog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4431,4 +4431,7 @@ v0.92.0.11:
- towny.command.plot.group.forsale: true
- towny.command.plot.group.notforsale: true
- Allow for other plugins to modify the TownPreClaim cancellation message.
- Closes #3814.
- Closes #3814.
- Remove /town unclaim outpost from /town unclaim ?
- Add /ta unclaim & /plot unclaim tab completes.
- Closes #3883.
1 change: 1 addition & 0 deletions src/com/palmergames/bukkit/towny/command/PlotCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ public List<String> onTabComplete(CommandSender sender, Command command, String
return NameUtil.filterByStart(plotToggleTabCompletes, args[1]);
break;
case "claim":
case "unclaim":
case "notforsale":
case "nfs":
if (args.length == 2)
Expand Down
6 changes: 2 additions & 4 deletions src/com/palmergames/bukkit/towny/command/TownCommand.java
Original file line number Diff line number Diff line change
Expand Up @@ -172,11 +172,10 @@ public class TownCommand extends BaseCommand implements CommandExecutor, TabComp
"rect"
);

private static final List<String> townUnclaimTabCompletes = Arrays.asList(
public static final List<String> townUnclaimTabCompletes = Arrays.asList(
"circle",
"rect",
"all",
"outpost"
"all"
);

private static List<String> townInviteTabCompletes = Arrays.asList(
Expand Down Expand Up @@ -3344,7 +3343,6 @@ public static void parseTownUnclaimCommand(Player player, String[] split) {
player.sendMessage(ChatTools.formatCommand(TownySettings.getLangString("mayor_sing"), "/town unclaim", "", TownySettings.getLangString("mayor_help_6")));
player.sendMessage(ChatTools.formatCommand(TownySettings.getLangString("mayor_sing"), "/town unclaim", "[circle/rect] [radius]", TownySettings.getLangString("mayor_help_7")));
player.sendMessage(ChatTools.formatCommand(TownySettings.getLangString("mayor_sing"), "/town unclaim", "all", TownySettings.getLangString("mayor_help_8")));
player.sendMessage(ChatTools.formatCommand(TownySettings.getLangString("mayor_sing"), "/town unclaim", "outpost", TownySettings.getLangString("mayor_help_9")));
} else {
Resident resident;
Town town;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,9 @@ public List<String> onTabComplete(CommandSender sender, Command command, String
return getTownyStartingWith(args[3], "t");
}
break;
case "unclaim":
if (args.length == 2)
return NameUtil.filterByStart(TownCommand.townUnclaimTabCompletes, args[1]);
default:
if (args.length == 1)
return NameUtil.filterByStart(adminTabCompletes, args[0]);
Expand Down

0 comments on commit 7cccef6

Please sign in to comment.