View Single Post
Re: WriteDest_Parm: not a client
Old
  (#2)
KWo
Developer of PODBot mm
 
KWo's Avatar
 
Status: Offline
Posts: 3,425
Join Date: Apr 2004
Default Re: WriteDest_Parm: not a client - 24-02-2008

It looks either like is_user_bot is not working for You correctly or there is something else crashing Your server...
Try the latest beta (download it from here - just replace the dll only)
and in Your code replace the function Util_Is_Valid_Player by this one:
Code:
bool:Util_Is_Valid_Player( id )
{
 if( id < 1 || id > MAX_PLAYERS )
 {
  return false;
 }
 if( (!is_user_connected( id )) || (!pev_valid( id )) )
 {
  return false;
 }
if ( pev( id, pev_flags ) & FL_CLIENT ) 
 {
  return true;
 }
 return false;
}  
Another problem is this - if there is a delay between checking if the player is valid and sending the message to him (for example set_task function), it may fail, too. You need to check the player in the moment just before sending to him the message.
  
Reply With Quote