Some more hard-coded text removal

This commit is contained in:
Joonas Rikkonen
2017-12-27 14:40:33 +02:00
parent 2894b74edc
commit 4f0b190371
12 changed files with 135 additions and 82 deletions
@@ -166,11 +166,11 @@ namespace Barotrauma.Networking
if (c.ChatSpamCount > 3)
{
//kick for spamming too much
GameMain.Server.KickClient(c, "You have been kicked by the spam filter.");
GameMain.Server.KickClient(c, TextManager.Get("SpamFilterKicked"));
}
else
{
ChatMessage denyMsg = ChatMessage.Create("", "You have been blocked by the spam filter. Try again after 10 seconds.", ChatMessageType.Server, null);
ChatMessage denyMsg = Create("", TextManager.Get("SpamFilterBlocked"), ChatMessageType.Server, null);
c.ChatSpamTimer = 10.0f;
GameMain.Server.SendChatMessage(denyMsg, c);
}
@@ -181,7 +181,7 @@ namespace Barotrauma.Networking
if (c.ChatSpamTimer > 0.0f)
{
ChatMessage denyMsg = ChatMessage.Create("", "You have been blocked by the spam filter. Try again after 10 seconds.", ChatMessageType.Server, null);
ChatMessage denyMsg = Create("", TextManager.Get("SpamFilterBlocked"), ChatMessageType.Server, null);
c.ChatSpamTimer = 10.0f;
GameMain.Server.SendChatMessage(denyMsg, c);
return;
@@ -54,13 +54,6 @@ namespace Barotrauma
text = text.Replace("[" + inputType.ToString() + "]", GameMain.Config.KeyBind(inputType).ToString());
}
#endif
if (Submarine.MainSub != null) text = text.Replace("[sub]", Submarine.MainSub.Name);
if (GameMain.GameSession != null && GameMain.GameSession.StartLocation != null)
{
text = text.Replace("[location]", GameMain.GameSession.StartLocation.Name);
}
return text;
}
}