Fix for "allianceChatFormat" not actually being used, updated default format for it
This commit is contained in:
parent
f5450886f1
commit
1c02b35193
@ -58,8 +58,8 @@ public class Conf
|
||||
public static boolean chatTagPadBefore = false;
|
||||
public static boolean chatTagPadAfter = true;
|
||||
public static String chatTagFormat = "%s"+ChatColor.WHITE;
|
||||
public static String factionChatFormat = "%s"+ChatColor.WHITE+" %s";
|
||||
public static String allianceChatFormat = "%s"+ChatColor.WHITE+" %s";
|
||||
public static String factionChatFormat = "%s:"+ChatColor.WHITE+" %s";
|
||||
public static String allianceChatFormat = ChatColor.LIGHT_PURPLE+"%s:"+ChatColor.WHITE+" %s";
|
||||
|
||||
public static double autoLeaveAfterDaysOfInactivity = 14.0;
|
||||
|
||||
|
@ -73,21 +73,19 @@ public class FactionsChatEarlyListener extends PlayerListener
|
||||
{
|
||||
Faction myFaction = me.getFaction();
|
||||
|
||||
String factionAndName = ChatColor.stripColor(me.getNameAndTag());
|
||||
String message = Conf.colorAlly+factionAndName+ChatColor.WHITE+" "+msg;
|
||||
String message = String.format(Conf.allianceChatFormat, ChatColor.stripColor(me.getNameAndTag()), msg);
|
||||
|
||||
//Send message to our own faction
|
||||
myFaction.sendMessage(message);
|
||||
|
||||
//Send to all our allies
|
||||
for (FPlayer fplayer : FPlayers.i.getOnline())
|
||||
{
|
||||
if(myFaction.getRelationTo(fplayer) == Relation.ALLY)
|
||||
{
|
||||
//Send to all our allies
|
||||
fplayer.sendMessage(message);
|
||||
}
|
||||
}
|
||||
|
||||
P.p.log(Level.INFO, ChatColor.stripColor("AllianceChat "+me.getFaction().getTag()+": "+message));
|
||||
P.p.log(Level.INFO, ChatColor.stripColor("AllianceChat: "+message));
|
||||
|
||||
event.setCancelled(true);
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user