mirror of
https://github.com/filoghost/ChestCommands.git
synced 2024-11-22 18:16:14 +01:00
Support colors in PERMISSION-MESSAGE
This commit is contained in:
parent
2ec403ba8e
commit
b90fa741c5
@ -6,18 +6,19 @@
|
|||||||
package me.filoghost.chestcommands.attribute;
|
package me.filoghost.chestcommands.attribute;
|
||||||
|
|
||||||
import me.filoghost.chestcommands.icon.InternalConfigurableIcon;
|
import me.filoghost.chestcommands.icon.InternalConfigurableIcon;
|
||||||
|
import me.filoghost.fcommons.Colors;
|
||||||
|
|
||||||
public class ClickPermissionMessageAttribute implements IconAttribute {
|
public class ClickPermissionMessageAttribute implements IconAttribute {
|
||||||
|
|
||||||
private final String clickPermissionMessage;
|
private final String message;
|
||||||
|
|
||||||
public ClickPermissionMessageAttribute(String clickPermissionMessage, AttributeErrorHandler errorHandler) {
|
public ClickPermissionMessageAttribute(String serializedMessage, AttributeErrorHandler errorHandler) {
|
||||||
this.clickPermissionMessage = clickPermissionMessage;
|
this.message = Colors.addColors(serializedMessage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void apply(InternalConfigurableIcon icon) {
|
public void apply(InternalConfigurableIcon icon) {
|
||||||
icon.setNoClickPermissionMessage(clickPermissionMessage);
|
icon.setNoClickPermissionMessage(message);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user