Commit 682b027a authored by CS_Birb's avatar CS_Birb Committed by CS_Birb

Merge branch 'master' into 'Birb-Dev/1.15'

Checking for placeholder

See merge request !1
parents d736e494 4f7fac1c
......@@ -393,8 +393,20 @@ public class MPlayer extends SenderEntity<MPlayer>
this.msg(progress + "<g>You will receive a reward!", totalMax, totalMax, 100 + "%");
String name = MConf.get().getRandomReward();
String displayName = this.getDisplayName(null);
// Apply the week and year variables
String friendlyName = name;
friendlyName = friendlyName.replace("{w}", String.valueOf(MassiveTickets.getCurrentWeek()));
friendlyName = friendlyName.replace("{y}", String.valueOf(MassiveTickets.getCurrentYear()));
// Apply moderator name variable, if possible
friendlyName = friendlyName.replace("{m}", IdUtil.getName(id));
// Apply the player name variable, if possible
if (playerId != null) friendlyName = friendlyName.replace("{p}", IdUtil.getName(playerId));
MassiveTickets.alertModeratorsMsg("<white>%s<pink> has done <aqua>%d <pink>tickets!", displayName, countAfter);
MassiveTickets.alertModeratorsMsg("<pink>Enjoy your <aqua>%s <white>%s<pink>!", name, displayName);
MassiveTickets.alertModeratorsMsg("<pink>Enjoy your <aqua>%s <white>%s<pink>!", friendlyName, displayName);
MConf.get().getRewardReaction(name).run(id, playerId);
MConf.get().getDoneReactionLevel().run(id, playerId);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment