Raised This Month: $ Target: $400
 0% 

difference between flags and is_user_bot


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 01-28-2009 , 13:30   difference between flags and is_user_bot
Reply With Quote #1

im wondering what the difference is between
Code:
is_user_bot(id)
and
Code:
(pev(id, pev_flags) & FL_FAKECLIENT)

whosyourdaddy is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 01-28-2009 , 13:48   Re: difference between flags and is_user_bot
Reply With Quote #2

Check only pev_flags may return false results, is_user_bot checks other things :

PHP Code:
__is_user_botid )
{
    if( 
<= id <= get_maxplayers() )
    {
        if( (
pev(idpev_flags) & FL_FAKECLIENT) == FL_FAKECLIENT) )
        {
            return 
1
        
}
        new 
szAuth[32]
        
get_user_authid(idszAuthcharsmax(szAuth))
        if( 
szAuth[0] && equal(szAuth"BOT") )
        {
            return 
1
        
}
    }
    return 
0

__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
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 01:46.


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