Raised This Month: $32 Target: $400
 8% 

Check spectators for admin-flags


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Independence
Junior Member
Join Date: Dec 2009
Location: Ukraine
Old 07-21-2010 , 10:55   Check spectators for admin-flags
Reply With Quote #1

Hi to all. I need little help with plugins for DOD:S. I need the plugin which will check spectators on admin privilegies. If user is a spectator and don't have admin permission (for example A-level), server will run some command in console.

Please, help me! This script is very important for me: it will prevent regular crashes of my server. Thanks.
Independence is offline
neo_gis
Member
Join Date: Sep 2009
Location: Rabat
Old 07-22-2010 , 07:30   Re: Check spectators for admin-flags
Reply With Quote #2

just loop through all clients , something like that :

PHP Code:
for (new 1<= GetClientCount(); i++)
{
    if (
IsFakeClient(i) || !IsClientInGame(i) || !IsClientConnected(i))
        continue;

    if (
GetClientTeam(i) != 1)
        continue;

    if (!
GetAdminFlag(iADMIN_FLAG))
    {
        
// Your Code Here
    
}

__________________
neo_gis is offline
Send a message via MSN to neo_gis Send a message via Skype™ to neo_gis
Reply



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 04:02.


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