Raised This Month: $ Target: $400
 0% 

Solved [CS GO]Admin Chat doesn't display nickname


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Danielej1
Senior Member
Join Date: Jul 2022
Location: Poland
Old 01-26-2023 , 11:35   [CS GO]Admin Chat doesn't display nickname
Reply With Quote #1

Hello i trying edit plugin Admin Chat because then plug doesn't display nick so The plugin uses the message as %s and I don't know how to do it because the username also uses %s, I don't know how I can explain it Sorry if anyone doesn't understand

Code:
#pragma semicolon 1

#define DEBUG

#define PLUGIN_AUTHOR "Trum | Trum#7913"
#define PLUGIN_VERSION "1.00"

#include <sourcemod>
#include <sdktools>

#pragma newdecls required

public Plugin myinfo = {
    name = "[CSGO] Admin Talk",
    author = "Trum | Trum#7913",
    description = "Custom chat message for admins",
    url = "http://discord.me/trum",
};

public void OnPluginStart()
{
    RegAdminCmd("sm_at", Command_AdminMessage, ADMFLAG_SLAY, "The admin talk command");
}

public Action Command_AdminMessage(int client, int args)
{
char name[MAX_NAME_LENGTH];
GetClientName(client, name, sizeof(name));
	{
    if(args < 1)
		{
       	 PrintToConsole(client, "Usage: sm_at <message>");
       	 return Plugin_Handled;
		}
    char Message[32];
    
    GetCmdArgString(Message, sizeof(Message));
    PrintToChatAll (" \x07[ADMIN]\x10%s: \x09", Message);
    
    return Plugin_Handled;
	}
}
Orginal Plugin : https://forums.alliedmods.net/showthread.php?t=310137

Last edited by Danielej1; 01-30-2023 at 12:09.
Danielej1 is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:24.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode