AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting (https://forums.alliedmods.net/forumdisplay.php?f=107)
-   -   Show Status in Chat (https://forums.alliedmods.net/showthread.php?t=315588)

kabLe795 04-14-2019 12:01

Show Status in Chat
 
I'm trying to make a plugin that will let the player type !status and show what would normally be found in the console for status in chat. Is this possible and if it is can anyone point me in the right direction? I have not been able to find any similar plugins to reference

blackdevil72 04-14-2019 13:24

Re: Show Status in Chat
 
HELLO.

I think you could go for something like this:

PHP Code:

for (int i 1<= MaxClientsi++)
{
    if ((
IsClientInGame(i) || IsClientObserver(i)) && IsClientConnected(i) && !IsFakeClient(i))
    {
        
PrintToChat(i"Name: %s || SteamID: %s"GetClientName(i), GetSteamAccountID(itrue)); 
    }


For the rest of the script I'll let you do.

I got everything I needed from there : https://sm.alliedmods.net/new-api/


All times are GMT -4. The time now is 15:29.

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