From 0bbf1948bf02972723c9689e783763fb6a9e7dbb Mon Sep 17 00:00:00 2001 From: Valentin Barat Date: Thu, 25 Apr 2024 01:02:46 +0200 Subject: [PATCH] Added localization in EN/FR --- Commands/basebans.cs | 4 ++-- lang/ar.json | 5 ++++- lang/en.json | 6 ++++-- lang/es.json | 5 ++++- lang/fa.json | 5 ++++- lang/fr.json | 5 ++++- lang/lv.json | 5 ++++- lang/pl.json | 5 ++++- lang/pt-BR.json | 5 ++++- lang/ru.json | 5 ++++- lang/tr.json | 5 ++++- lang/zh-Hans.json | 5 ++++- 12 files changed, 46 insertions(+), 14 deletions(-) diff --git a/Commands/basebans.cs b/Commands/basebans.cs index 42ef54c..336959c 100644 --- a/Commands/basebans.cs +++ b/Commands/basebans.cs @@ -387,14 +387,14 @@ namespace CS2_SimpleAdmin if (duration > Config.MaxBanDuration && canPermBan == false) { if (validCaller) - caller.PrintToChat($"[Simple Admin] Ban duration cannot exceed {Config.MaxBanDuration} minutes."); + caller.PrintToChat($"{_localizer["sa_prefix"]} {_localizer["sa_ban_max_duration_exceeded", Config.MaxBanDuration]}"); return false; } if (duration == 0 && canPermBan == false) { if (validCaller) - caller.PrintToChat($"[Simple Admin] You do not have the right to permanently ban."); + caller.PrintToChat($"{_localizer!["sa_prefix"]} {_localizer["sa_ban_perm_restricted"]}"); return false; } diff --git a/lang/ar.json b/lang/ar.json index 02e81ce..ccfa14c 100644 --- a/lang/ar.json +++ b/lang/ar.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(مسؤول) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(لاعب) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** أصدر الأمر `{1}` على الخادم `HOSTNAME`" + "sa_discord_log_command": "**{0}** أصدر الأمر `{1}` على الخادم `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/en.json b/lang/en.json index a2d39ce..3daa930 100644 --- a/lang/en.json +++ b/lang/en.json @@ -58,6 +58,8 @@ "sa_adminsay_prefix": "{RED}ADMIN: {lightred}{0}{default}", "sa_adminchat_template_admin": "{LIME}(ADMIN) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(PLAYER) {lightred}{0}{default}: {lightred}{1}{default}", - - "sa_discord_log_command": "**{0}** issued command `{1}` on server `HOSTNAME`" + "sa_discord_log_command": "**{0}** issued command `{1}` on server `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/es.json b/lang/es.json index cd1c49c..525cbfa 100644 --- a/lang/es.json +++ b/lang/es.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(ADMIN) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(JUGADOR) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** emitió el comando `{1}` en el servidor `HOSTNAME`" + "sa_discord_log_command": "**{0}** emitió el comando `{1}` en el servidor `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/fa.json b/lang/fa.json index 1c057ba..596af20 100644 --- a/lang/fa.json +++ b/lang/fa.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(مدیر) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(بازیکن) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** دستور `{1}` را در سرور `HOSTNAME` اجرا کرد" + "sa_discord_log_command": "**{0}** دستور `{1}` را در سرور `HOSTNAME` اجرا کرد", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/fr.json b/lang/fr.json index 27797e7..c54aca7 100644 --- a/lang/fr.json +++ b/lang/fr.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(ADMIN) {lightred}{0}{default} : {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(JOUEUR) {lightred}{0}{default} : {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** a exécuté la commande `{1}` sur le serveur `HOSTNAME`" + "sa_discord_log_command": "**{0}** a exécuté la commande `{1}` sur le serveur `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "La durée d'un bannissement ne peut dépasser {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "Tu ne peux pas bannir de manière permanente" } \ No newline at end of file diff --git a/lang/lv.json b/lang/lv.json index f8e2ea1..51c7408 100644 --- a/lang/lv.json +++ b/lang/lv.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(Admins) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(SPĒLĒTĀJS) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** izmantoja komandu `{1}` uz servera `HOSTNAME`" + "sa_discord_log_command": "**{0}** izmantoja komandu `{1}` uz servera `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/pl.json b/lang/pl.json index 2ddddd7..4baaa83 100644 --- a/lang/pl.json +++ b/lang/pl.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(ADMIN) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(GRACZ) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** użył komendy `{1}` na serwerze `HOSTNAME`" + "sa_discord_log_command": "**{0}** użył komendy `{1}` na serwerze `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/pt-BR.json b/lang/pt-BR.json index b8a987d..84db1be 100644 --- a/lang/pt-BR.json +++ b/lang/pt-BR.json @@ -59,5 +59,8 @@ "sa_adminchat_template_admin": "{LIME}(ADMIN) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(JOGADOR) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** emitiu o comando `{1}` no servidor `HOSTNAME`" + "sa_discord_log_command": "**{0}** emitiu o comando `{1}` no servidor `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/ru.json b/lang/ru.json index 6b30dd0..0d0645d 100644 --- a/lang/ru.json +++ b/lang/ru.json @@ -58,5 +58,8 @@ "sa_adminchat_template_admin": "{LIME}(АДМИНИСТРАТОР) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(ИГРОК) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** выполнил команду `{1}` на сервере `HOSTNAME`" + "sa_discord_log_command": "**{0}** выполнил команду `{1}` на сервере `HOSTNAME`", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/tr.json b/lang/tr.json index b337b6d..9b457de 100644 --- a/lang/tr.json +++ b/lang/tr.json @@ -58,5 +58,8 @@ "sa_adminchat_template_admin": "{LIME}(YÖNETİCİ) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(OYUNCU) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}**, sunucuda `HOSTNAME` üzerinde `{1}` komutunu gerçekleştirdi!" + "sa_discord_log_command": "**{0}**, sunucuda `HOSTNAME` üzerinde `{1}` komutunu gerçekleştirdi!", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file diff --git a/lang/zh-Hans.json b/lang/zh-Hans.json index 895c242..5f2ebb4 100644 --- a/lang/zh-Hans.json +++ b/lang/zh-Hans.json @@ -58,5 +58,8 @@ "sa_adminchat_template_admin": "{LIME}(管理员) {lightred}{0}{default}: {lightred}{1}{default}", "sa_adminchat_template_player": "{SILVER}(玩家) {lightred}{0}{default}: {lightred}{1}{default}", - "sa_discord_log_command": "**{0}** 在服务器 `HOSTNAME` 上执行了命令 `{1}`!" + "sa_discord_log_command": "**{0}** 在服务器 `HOSTNAME` 上执行了命令 `{1}`!", + + "sa_ban_max_duration_exceeded": "Ban duration cannot exceed {lightred}{0}{default} minutes.", + "sa_ban_perm_restricted": "You do not have the right to permanently ban." } \ No newline at end of file