We have added the ability for the Mute to contain a reason, which is stored for the duration of the mute in the user's data file. Currently we need to add in the mute reason code into some other commands such as /afk and /me and /seen ect. We will also need to fix a problem with the reason when we dont add in a time frame for the mute, which should mute the player indefinatly rather then cancelling the mute and throwing a DataFormat exception.

This commit is contained in:
CreedTheFreak 2017-09-03 14:41:32 -07:00
parent 3512c4c8e6
commit 4ff9fe8666
4 changed files with 16 additions and 3 deletions

View file

@ -521,8 +521,12 @@ public abstract class UserData extends PlayerExtension implements IConf {
}
public void setMuteReason (String reason) {
muteReason = reason;
config.setProperty ("muteReason", reason);
if (reason.equals("")) {
config.removeProperty ("muteReason");
} else {
muteReason = reason;
config.setProperty ("muteReason", reason);
}
config.save();
}