diff --git a/Core/src/main/java/com/plotsquared/core/command/Backup.java b/Core/src/main/java/com/plotsquared/core/command/Backup.java index ff45fc80a..da0fa5a4e 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Backup.java +++ b/Core/src/main/java/com/plotsquared/core/command/Backup.java @@ -141,14 +141,14 @@ public final class Backup extends Command { player.sendMessage(TranslatableCaption.of("errors.not_in_plot")); } else if (!plot.hasOwner()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_unowned") ); } else if (plot.getVolume() > Integer.MAX_VALUE) { player.sendMessage(TranslatableCaption.of("schematics.schematic_too_large")); } else if (plot.isMerged()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_merged") ); } else if (!plot.isOwner(player.getUUID()) && !Permissions @@ -161,7 +161,7 @@ public final class Backup extends Command { final BackupProfile backupProfile = Objects.requireNonNull(this.backupManager.getProfile(plot)); if (backupProfile instanceof NullBackupProfile) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_other") ); } else { @@ -195,12 +195,12 @@ public final class Backup extends Command { player.sendMessage(TranslatableCaption.of("errors.not_in_plot")); } else if (!plot.hasOwner()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_unowned") ); } else if (plot.isMerged()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_merged") ); } else if (plot.getVolume() > Integer.MAX_VALUE) { @@ -215,7 +215,7 @@ public final class Backup extends Command { final BackupProfile backupProfile = Objects.requireNonNull(this.backupManager.getProfile(plot)); if (backupProfile instanceof NullBackupProfile) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_other") ); } else { @@ -266,12 +266,12 @@ public final class Backup extends Command { player.sendMessage(TranslatableCaption.of("errors.not_in_plot")); } else if (!plot.hasOwner()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_unowned") ); } else if (plot.isMerged()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_merged") ); } else if (plot.getVolume() > Integer.MAX_VALUE) { @@ -301,7 +301,7 @@ public final class Backup extends Command { final BackupProfile backupProfile = Objects.requireNonNull(this.backupManager.getProfile(plot)); if (backupProfile instanceof NullBackupProfile) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_other") ); } else { @@ -315,7 +315,7 @@ public final class Backup extends Command { } else { if (number < 1 || number > backups.size()) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_invalid_choice") ); } else { @@ -324,7 +324,7 @@ public final class Backup extends Command { if (backup == null || backup.getFile() == null || !Files .exists(backup.getFile())) { player.sendMessage( - TranslatableCaption.of("backup_impossible"), + TranslatableCaption.of("backups.backup_impossible"), Template.of("plot", "generic.generic_invalid_choice") ); } else { diff --git a/Core/src/main/java/com/plotsquared/core/command/Copy.java b/Core/src/main/java/com/plotsquared/core/command/Copy.java index 194f48cbc..fa9f98cb6 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Copy.java +++ b/Core/src/main/java/com/plotsquared/core/command/Copy.java @@ -80,7 +80,8 @@ public class Copy extends SubCommand { plot1.getPlotModificationManager().copy(plot2, player).thenAccept(result -> { if (result) { - player.sendMessage(TranslatableCaption.of("move.copy_success")); + player.sendMessage(TranslatableCaption.of("move.copy_success"), Template.of("origin", String.valueOf(plot1)), + Template.of("target", String.valueOf(plot2))); } else { player.sendMessage(TranslatableCaption.of("move.requires_unowned")); } diff --git a/Core/src/main/java/com/plotsquared/core/command/Move.java b/Core/src/main/java/com/plotsquared/core/command/Move.java index c4abb199d..23694db72 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Move.java +++ b/Core/src/main/java/com/plotsquared/core/command/Move.java @@ -112,7 +112,8 @@ public class Move extends SubCommand { return plot1.getPlotModificationManager().move(plot2, player, () -> { }, false).thenApply(result -> { if (result) { - player.sendMessage(TranslatableCaption.of("move.move_success")); + player.sendMessage(TranslatableCaption.of("move.move_success"), Template.of("origin", String.valueOf(plot1)), + Template.of("target", String.valueOf(plot2))); return true; } else { player.sendMessage(TranslatableCaption.of("move.requires_unowned")); diff --git a/Core/src/main/java/com/plotsquared/core/command/Swap.java b/Core/src/main/java/com/plotsquared/core/command/Swap.java index d2070a67b..f0935287c 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Swap.java +++ b/Core/src/main/java/com/plotsquared/core/command/Swap.java @@ -89,7 +89,8 @@ public class Swap extends SubCommand { return plot1.getPlotModificationManager().move(plot2, player, () -> { }, true).thenApply(result -> { if (result) { - player.sendMessage(TranslatableCaption.of("swap.swap_success")); + player.sendMessage(TranslatableCaption.of("swap.swap_success"), Template.of("origin", String.valueOf(plot1)), + Template.of("target", String.valueOf(plot2))); return true; } else { player.sendMessage(TranslatableCaption.of("swap.swap_overlap")); diff --git a/Core/src/main/resources/lang/messages_en.json b/Core/src/main/resources/lang/messages_en.json index af96d3aa7..0c600b016 100644 --- a/Core/src/main/resources/lang/messages_en.json +++ b/Core/src/main/resources/lang/messages_en.json @@ -2,9 +2,9 @@ "confirm.expired_confirm": "Confirmation has expired, please run the command again!", "confirm.failed_confirm": "You have no pending actions to confirm!", "confirm.requires_confirm": "Are you sure you wish to execute: ?\nThis cannot be undone! If you are sure: ", - "move.move_success": "Successfully moved plot.", + "move.move_success": "Successfully moved the plot -> ", "move.move_merged": "Merged plots may not be moved. Please unmerge the plot before performing the move.", - "move.copy_success": "Successfully copied plot.", + "move.copy_success": "Successfully copied plots -> ", "move.requires_unowned": "The location specified is already occupied.", "debug.requires_unmerged": "The plot cannot be merged.", "debug.debug_header": " Debug Information\n", @@ -60,7 +60,7 @@ "notification.notify_enter": " entered your plot ().", "notification.notify_leave": " left your plot ().", "swap.swap_overlap": "The proposed areas are not allowed to overlap.", - "swap.swap_success": "Successfully swapped plots.", + "swap.swap_success": "Successfully swapped plots -> ", "swap.swap_merged": "Merged plots may not be swapped. Please unmerge the plots before performing the swap.", "swap.progress_region1_copy": "Current region 1 copy progress: %", "swap.progress_region2_copy": "Current region 2 copy progress: %Result: grants left.", "grants.added": " grant(s) have been added.", "events.event_denied": " Cancelled by external plugin.", - "backups.backup_impossible": "Backups are not enabled for this plot: .", + "backups.backup_impossible": "Backups are not enabled for this plot: .", "backups.backup_save_success": "The backup was created successfully.", "backups.backup_save_failed": "The backup could not be created: ", "backups.backup_load_success": "The backup was restored successfully.",