mirror of
https://github.com/garbagemule/MobArena.git
synced 2024-11-26 04:25:21 +01:00
Add specific Msg value for /ma addreward
.
This commit introduces a new announcement value for the `addreward` command. This allows server owners to completely remove the message by setting it to the empty string while retaining wave reward messages. In general, we shouldn't reuse announcements unless the actions that send them are identical, because it makes everything a lot more tangled than it has to be.
This commit is contained in:
parent
dafae0cf07
commit
efc66820c6
@ -78,6 +78,7 @@ public enum Msg {
|
|||||||
WAVE_BOSS_KILLED("&a%&r killed the boss!"),
|
WAVE_BOSS_KILLED("&a%&r killed the boss!"),
|
||||||
WAVE_BOSS_REWARD_EARNED("You earned: &e%"),
|
WAVE_BOSS_REWARD_EARNED("You earned: &e%"),
|
||||||
WAVE_REWARD("You just earned a reward: &e%&r"),
|
WAVE_REWARD("You just earned a reward: &e%&r"),
|
||||||
|
MISC_REWARD_ADDED("You were just given a reward: &e%&r"),
|
||||||
MISC_LIST_PLAYERS("Live players: &a%&r"),
|
MISC_LIST_PLAYERS("Live players: &a%&r"),
|
||||||
MISC_LIST_ARENAS("Available arenas: %"),
|
MISC_LIST_ARENAS("Available arenas: %"),
|
||||||
MISC_COMMAND_NOT_ALLOWED("You can't use that command in the arena!"),
|
MISC_COMMAND_NOT_ALLOWED("You can't use that command in the arena!"),
|
||||||
|
@ -64,7 +64,7 @@ public class AddRewardCommand implements Command {
|
|||||||
}
|
}
|
||||||
|
|
||||||
arena.getRewardManager().addReward(player, thing);
|
arena.getRewardManager().addReward(player, thing);
|
||||||
arena.getMessenger().tell(player, Msg.WAVE_REWARD, thing.toString());
|
arena.getMessenger().tell(player, Msg.MISC_REWARD_ADDED, thing.toString());
|
||||||
|
|
||||||
String msg = "Added " + ChatColor.YELLOW + thing + ChatColor.RESET + " to " + ChatColor.YELLOW + player.getName() + "'s" + ChatColor.RESET + " rewards.";
|
String msg = "Added " + ChatColor.YELLOW + thing + ChatColor.RESET + " to " + ChatColor.YELLOW + player.getName() + "'s" + ChatColor.RESET + " rewards.";
|
||||||
am.getGlobalMessenger().tell(sender, msg);
|
am.getGlobalMessenger().tell(sender, msg);
|
||||||
|
Loading…
Reference in New Issue
Block a user