Changed chat formatting to support (and depend on) TownyChat
This commit is contained in:
parent
9777999fe7
commit
4421ac041b
9 changed files with 15 additions and 7 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -10,4 +10,6 @@ commands:
|
|||
usage: "&cUsage: /nrp <message>&r"
|
||||
ooc:
|
||||
description: Send message in Out-of-Character
|
||||
usage: "&cUsage: /ooc <message>&r"
|
||||
usage: "&cUsage: /ooc <message>&r"
|
||||
author: NorbiPeti
|
||||
depend: [Essentials, Towny]
|
||||
|
|
|
@ -174,12 +174,18 @@ public class PlayerListener implements Listener { // 2015.07.16.
|
|||
}
|
||||
}
|
||||
|
||||
event.setFormat("<"
|
||||
+ (player.RPMode ? (ShowRPTag ? "§2[RP]§r" : "") : "§8[OOC]§r")
|
||||
+ event.getFormat().substring(
|
||||
event.getFormat().indexOf("<") + 1,
|
||||
event.getFormat().indexOf(">")) + flair + "> "
|
||||
+ message); // 2015.08.08.
|
||||
/*
|
||||
* event.setFormat("<" + (player.RPMode ? (ShowRPTag ? "§2[RP]§r" : "")
|
||||
* : "§8[OOC]§r") + event.getFormat().substring(
|
||||
* event.getFormat().indexOf("<") + 1, event.getFormat().indexOf(">")) +
|
||||
* flair + "> " + message); // 2015.08.08.
|
||||
*/
|
||||
event.setFormat(event
|
||||
.getFormat()
|
||||
.replace(
|
||||
"{rptag}",
|
||||
(player.RPMode ? (ShowRPTag ? "§2[RP]§r" : "")
|
||||
: "§8[OOC]§r")).replace("{buttonflair}", flair)); // 2015.09.04.
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue