diff --git a/core/smn_console.cpp b/core/smn_console.cpp index 318c3fae..2e71c7f8 100644 --- a/core/smn_console.cpp +++ b/core/smn_console.cpp @@ -1097,6 +1097,8 @@ static cell_t FakeClientCommand(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Client %d is not connected", params[1]); } + g_SourceMod.SetGlobalTarget(params[1]); + char buffer[256]; g_SourceMod.FormatString(buffer, sizeof(buffer), pContext, params, 2); @@ -1124,6 +1126,8 @@ static cell_t FakeClientCommandEx(IPluginContext *pContext, const cell_t *params return pContext->ThrowNativeError("Client %d is not connected", params[1]); } + g_SourceMod.SetGlobalTarget(params[1]); + char buffer[256]; g_SourceMod.FormatString(buffer, sizeof(buffer), pContext, params, 2); @@ -1172,8 +1176,6 @@ static cell_t ReplyToCommand(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Client %d is not connected", params[1]); } - g_SourceMod.SetGlobalTarget(params[1]); - unsigned int replyto = g_ChatTriggers.GetReplyTo(); if (replyto == SM_REPLY_CONSOLE) { diff --git a/core/smn_hudtext.cpp b/core/smn_hudtext.cpp index 37b034e6..5cc81448 100644 --- a/core/smn_hudtext.cpp +++ b/core/smn_hudtext.cpp @@ -394,6 +394,7 @@ static cell_t ShowSyncHudText(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Client %d is not in-game", client); } + g_SourceMod.SetGlobalTarget(client); g_SourceMod.FormatString(message_buffer, sizeof(message_buffer), pContext, params, 3); if (pContext->GetLastNativeError() != SP_ERROR_NONE) { @@ -466,6 +467,7 @@ static cell_t ShowHudText(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Client %d is not in-game", client); } + g_SourceMod.SetGlobalTarget(client); g_SourceMod.FormatString(message_buffer, sizeof(message_buffer), pContext, params, 3); if (pContext->GetLastNativeError() != SP_ERROR_NONE) { diff --git a/core/smn_menus.cpp b/core/smn_menus.cpp index 9aa856da..6f9eef8f 100644 --- a/core/smn_menus.cpp +++ b/core/smn_menus.cpp @@ -844,8 +844,6 @@ static cell_t SetMenuTitle(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Menu handle %x is invalid (error %d)", hndl, err); } - g_SourceMod.SetGlobalTarget(SOURCEMOD_SERVER_LANGUAGE); - char buffer[1024]; g_SourceMod.FormatString(buffer, sizeof(buffer), pContext, params, 2); diff --git a/plugins/adminhelp.sp b/plugins/adminhelp.sp index a13269f1..3e927229 100644 --- a/plugins/adminhelp.sp +++ b/plugins/adminhelp.sp @@ -82,7 +82,7 @@ public Action:HelpCmd(client, args) new Flags; new Handle:CmdIter = GetCommandIterator(); - FormatEx(NoDesc, sizeof(NoDesc), "%t", "No description available"); + FormatEx(NoDesc, sizeof(NoDesc), "%T", "No description available", client); if (DoSearch) { diff --git a/plugins/basecommands/who.sp b/plugins/basecommands/who.sp index 2897d14b..6011406c 100644 --- a/plugins/basecommands/who.sp +++ b/plugins/basecommands/who.sp @@ -175,9 +175,9 @@ public Action:Command_Who(client, args) { /* Display header */ decl String:t_access[16], String:t_name[16], String:t_username[16]; - Format(t_access, sizeof(t_access), "%t", "Admin access", client); - Format(t_name, sizeof(t_name), "%t", "Name", client); - Format(t_username, sizeof(t_username), "%t", "Username", client); + Format(t_access, sizeof(t_access), "%T", "Admin access", client); + Format(t_name, sizeof(t_name), "%T", "Name", client); + Format(t_username, sizeof(t_username), "%T", "Username", client); if (is_admin) { diff --git a/plugins/nominations.sp b/plugins/nominations.sp index b6554341..c00e1e6f 100644 --- a/plugins/nominations.sp +++ b/plugins/nominations.sp @@ -260,7 +260,7 @@ public Action:Command_Nominate(client, args) AttemptNominate(client) { - SetMenuTitle(g_MapMenu, "%t", "Nominate Title", client); + SetMenuTitle(g_MapMenu, "%T", "Nominate Title", client); DisplayMenu(g_MapMenu, client, MENU_TIME_FOREVER); return;