Fix for bail breaking is_user_bot - amb914
This still doesn't cache since that proved to be buggy; this will check the flag first, and then auth second.
This commit is contained in:
parent
bd3b7fc70c
commit
dd55716f15
@ -130,7 +130,18 @@ public:
|
|||||||
|
|
||||||
inline bool IsBot()
|
inline bool IsBot()
|
||||||
{
|
{
|
||||||
return ((pEdict->v.flags & FL_FAKECLIENT) == FL_FAKECLIENT);
|
if ((pEdict->v.flags & FL_FAKECLIENT) == FL_FAKECLIENT)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *auth = GETPLAYERAUTHID(pEdict);
|
||||||
|
if (auth && (strcmp(auth, "BOT") == 0))
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool IsAlive()
|
inline bool IsAlive()
|
||||||
|
Loading…
Reference in New Issue
Block a user