Raised This Month: $ Target: $400
 0% 

Print To All Admins


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
exvel
SourceMod Donor
Join Date: Jun 2006
Location: Russia
Old 11-12-2009 , 14:07   Re: Print To All Admins
Reply With Quote #5

Quote:
Originally Posted by FaTony View Post
I'm using this:
PHP Code:
public InformAdmin (const String:rawmessage[], any:...)
{
    new 
String:message[MESSAGE_LENGTH];
    
VFormat(messageMESSAGE_LENGTHrawmessage2);
    new 
AdminId:id=INVALID_ADMIN_ID;
    
PrintToServer(message);
    new 
clients=GetClientCount();
    for (new 
i=1;i<=clients;i++) {
        if (
IsClientConnected(i)) {
            
id=GetUserAdmin(i);
            if (
id!=INVALID_ADMIN_ID) {
                
PrintToConsole(imessage);
                
PrintToChat(imessage);
                }
            }
        }

Use IsClientInGame instead of IsClientConnected. Or there may be erros.
__________________
For admins: My plugins

For developers: Colors library
exvel is offline
Send a message via ICQ to exvel
 



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 14:16.


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