From 32052e63e2525204039ee25f458f244366aeb25b Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Mon, 6 Aug 2012 11:29:38 -0500 Subject: [PATCH] Don't send duplicate messages for Gamemode and Time commands. Gamemode gets sent with the packet. By: feildmaster --- .../main/java/org/bukkit/command/defaults/GameModeCommand.java | 2 -- .../src/main/java/org/bukkit/command/defaults/TimeCommand.java | 2 -- 2 files changed, 4 deletions(-) diff --git a/paper-api/src/main/java/org/bukkit/command/defaults/GameModeCommand.java b/paper-api/src/main/java/org/bukkit/command/defaults/GameModeCommand.java index 087363a055..08e5a90a1f 100644 --- a/paper-api/src/main/java/org/bukkit/command/defaults/GameModeCommand.java +++ b/paper-api/src/main/java/org/bukkit/command/defaults/GameModeCommand.java @@ -62,8 +62,6 @@ public class GameModeCommand extends VanillaCommand { } else { Command.broadcastCommandMessage(sender, "Set " + player.getName() + "'s game mode to" + mode.toString() + " mode", false); } - - player.sendMessage("Your game mode has been changed"); } } else { sender.sendMessage(player.getName() + " already has game mode " + mode.getValue()); diff --git a/paper-api/src/main/java/org/bukkit/command/defaults/TimeCommand.java b/paper-api/src/main/java/org/bukkit/command/defaults/TimeCommand.java index 9cc160ecec..9866877d25 100644 --- a/paper-api/src/main/java/org/bukkit/command/defaults/TimeCommand.java +++ b/paper-api/src/main/java/org/bukkit/command/defaults/TimeCommand.java @@ -42,7 +42,6 @@ public class TimeCommand extends VanillaCommand { } Command.broadcastCommandMessage(sender, "Set time to " + value); - sender.sendMessage("Set time to " + value); } else if (args[0].equals("add")) { if (!sender.hasPermission("bukkit.command.time.add")) { sender.sendMessage(ChatColor.RED + "You don't have permission to set the time"); @@ -56,7 +55,6 @@ public class TimeCommand extends VanillaCommand { } Command.broadcastCommandMessage(sender, "Added " + value + " to time"); - sender.sendMessage("Added " + value + " to time"); } else { sender.sendMessage("Unknown method. Usage: " + usageMessage); }