More i18n

Strings for player kick/ban, anti-cheating and server logs
This commit is contained in:
SGKoishi 2022-11-02 13:40:32 -07:00
parent d38046d74b
commit fde43a7730
No known key found for this signature in database
GPG key ID: 8FFC399070653828
10 changed files with 208 additions and 198 deletions

View file

@ -80,11 +80,11 @@ namespace TShockAPI
string msg = ex.BuildExceptionString();
//Give the console a brief
Console.ForegroundColor = ConsoleColor.Yellow;
Console.WriteLine($"UpdateManager warning: {msg}");
Console.WriteLine(GetString($"UpdateManager warning: {msg}"));
Console.ForegroundColor = ConsoleColor.Gray;
//And log the full exception
TShock.Log.Warn($"UpdateManager warning: {ex.ToString()}");
TShock.Log.ConsoleError("Retrying in 5 minutes.");
TShock.Log.Warn(GetString($"UpdateManager warning: {ex.ToString()}"));
TShock.Log.ConsoleError(GetString("Retrying in 5 minutes."));
CheckXMinutes = 5;
}
}
@ -117,8 +117,7 @@ namespace TShockAPI
{
reason = "none";
}
throw new WebException("Update server did not respond with an OK. "
+ $"Server message: [error {resp.StatusCode}] {reason}");
throw new WebException(GetString($"Update server did not respond with an OK. Server message: [error {resp.StatusCode}] {reason}"));
}
string json = await resp.Content.ReadAsStringAsync();