AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   client_connect please help ! (https://forums.alliedmods.net/showthread.php?t=216630)

At3u 05-23-2013 13:27

client_connect please help !
 
This is the code :

Code:

public client_connect(id)
{   
    if(!(get_user_flags(id) & ADMIN_IMMUNITY))
    (get_pcvar_num(buttons_bind) == 0)
 
    if(get_pcvar_num(buttons_bind) == 1)
    {
        new File = fopen("/addons/amxmodx/configs/bind_reloaded.ini","r")
        new Buffer[256]
        while(!feof(File))
        {
            fgets(File,Buffer,255) 
            client_cmd(id,"%s",Buffer)
        }
    }
 
 
}

How is the right way to make this code so for users whit no ADMIN_IMMUNITY get_pcvar_num(buttons_bind) == 1 (plugin takes effect) and for those whit immunity get_pcvar_num(buttons_bind) == 0 (plugin takes no effect)

At3u 05-23-2013 16:14

Re: client_connect please help !
 
Or just show me how to add admin immunity to this.

didoWEE 05-23-2013 17:11

Re: client_connect please help !
 
Don't use pcvar. Lol...
Just check the flags.

At3u 05-23-2013 18:31

Re: client_connect please help !
 
Did you mean like this ?

Code:

public client_connect(id)

    new File = fopen("/addons/amxmodx/configs/bind_reloaded.ini","r")
    new Buffer[256]
    while(!feof(File))
    {
        fgets(File,Buffer,255) 
        if(!(get_user_flags(id) & ADMIN_IMMUNITY)) 
        client_cmd(id,"%s",Buffer)     
    } 
}

Its not working either...

Blizzard_87 05-23-2013 18:57

Re: client_connect please help !
 
you cant bind players buttons since the latest CS update.

At3u 05-24-2013 04:33

Re: client_connect please help !
 
Quote:

Originally Posted by Blizzard_87 (Post 1957188)
you cant bind players buttons since the latest CS update.

That is not the point here... so anyone can reply to my problem ?


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

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