Raised This Month: $ Target: $400
 0% 

host_error: WriteDest_parm: not a client


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
taheri6
Member
Join Date: Mar 2006
Old 12-31-2007 , 16:10   host_error: WriteDest_parm: not a client
Reply With Quote #1

Hi all,

Ive seen a couple posts about this, from what I understand this occurs when a message is sent to "a person" who is not a client (like a bot?) or when a message is sent with out an ID.

Are these teh only times this message will occur?

Will doing a is_user_connecte(id) check before sending all messages be a good way to work arround this?

Does this only apply to hud messages (set_hudmessage/show_hudmessage) or does it also apply to client messages (client_print) ?
taheri6 is offline
kp_uparrow
Penalized Member
Join Date: Jun 2006
Location: 192.168.0.1
Old 01-01-2008 , 02:27   Re: host_error: WriteDest_parm: not a client
Reply With Quote #2

check is_user_connected(id) first, i think it applies to all messages
__________________
I USED A SECOND ACCOUNT TO DO MORE KARMA UPS AND DOWNS UNTIL GREENTRYST CAUGHT ME
kp_uparrow is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 01-01-2008 , 02:32   Re: host_error: WriteDest_parm: not a client
Reply With Quote #3

'client_print()' is a message, and the server won't crash if sent to a un-connected client. Same with a hud message. Tho.. I thought that if a message is sent reliably it will crash. Using "MSG_BROADCAST" and "MSG_ONE_UNRELIABLE" shouldn't crash a server.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
kp_uparrow
Penalized Member
Join Date: Jun 2006
Location: 192.168.0.1
Old 01-01-2008 , 15:47   Re: host_error: WriteDest_parm: not a client
Reply With Quote #4

but isnt client_print(id......... a client and is sent reliably?
__________________
I USED A SECOND ACCOUNT TO DO MORE KARMA UPS AND DOWNS UNTIL GREENTRYST CAUGHT ME
kp_uparrow is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 01-01-2008 , 23:54   Re: host_error: WriteDest_parm: not a client
Reply With Quote #5

Quote:
Originally Posted by kp_uparrow View Post
but isnt client_print(id......... a client and is sent reliably?
I didn't think so, but I checked the SDK. And I guess it is, though. It checks if the player is in-game before it sends the message. So, that's why it didn't crash. But as for the error he's getting. I was looking thought the HL-SDK. And the error is thrown when it's sent to an entity. Not a non-connected player.
I'm not so sure "is_user_connected()" would work, but using fakemeta, and:
Code:
if(pev(id,pev_flags) & FL_CLIENT)
would work.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
kp_uparrow
Penalized Member
Join Date: Jun 2006
Location: 192.168.0.1
Old 01-02-2008 , 00:17   Re: host_error: WriteDest_parm: not a client
Reply With Quote #6

i think is_user_connected(id) will work
__________________
I USED A SECOND ACCOUNT TO DO MORE KARMA UPS AND DOWNS UNTIL GREENTRYST CAUGHT ME
kp_uparrow is offline
taheri6
Member
Join Date: Mar 2006
Old 01-02-2008 , 15:05   Re: host_error: WriteDest_parm: not a client
Reply With Quote #7

what about something simple like this:

Code:
public Is_Valid_User( id )
{
    if( is_user_connected( id ) && ( pev( id, pev_flags ) & FL_CLIENT ) )
        return true;

    return false;
}
And then just call that each time instead?
__________________
http://www.yaur.com -=[Yaur]=- Clan Website
taheri6 is offline
taheri6
Member
Join Date: Mar 2006
Old 01-06-2008 , 07:00   Re: host_error: WriteDest_parm: not a client
Reply With Quote #8

ok, so I did this:

PHP Code:
public Util_Should_Message_Clientid )
{
    if( 
id == || id MAX_PLAYERS )
    {
        return 
false;
    }

    if( 
is_user_connectedid ) && !is_user_botid ) && is_user_alive(id) )
    {
        return 
true;
    }

    return 
false;

I have that set for anytime a client_print, hudmessage, or sound emit occurs

so
PHP Code:
if( Util_Should_Message_Clientid ) )
{
    
//Action

And I am still getting this occuring. Does this need to be set arround message_begin, ( anything in between like write_byte, write_short) , message_end, etc also?
__________________
http://www.yaur.com -=[Yaur]=- Clan Website
taheri6 is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 01-06-2008 , 14:04   Re: host_error: WriteDest_parm: not a client
Reply With Quote #9

Quote:
Originally Posted by taheri6 View Post
ok, so I did this:

PHP Code:
public Util_Should_Message_Clientid )
{
    if( 
id == || id MAX_PLAYERS )
    {
        return 
false;
    }

    if( 
is_user_connectedid ) && !is_user_botid ) && is_user_alive(id) )
    {
        return 
true;
    }

    return 
false;

I have that set for anytime a client_print, hudmessage, or sound emit occurs

so
PHP Code:
if( Util_Should_Message_Clientid ) )
{
    
//Action

And I am still getting this occuring. Does this need to be set arround message_begin, ( anything in between like write_byte, write_short) , message_end, etc also?
No, but if possible. Do you know the code that's causing it? If you do, post it.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
taheri6
Member
Join Date: Mar 2006
Old 01-06-2008 , 16:33   Re: host_error: WriteDest_parm: not a client
Reply With Quote #10

What types of messages do I need to do that with?

PHP Code:
#define MSG_BROADCAST        0    // unreliable to all
#define MSG_ONE            1    // reliable to one (msg_entity)
#define MSG_ALL            2    // reliable to all
#define MSG_INIT                     3    // write to the init string
#define MSG_PVS            4    // Ents in PVS of org
#define MSG_PAS            5    // Ents in PAS of org
#define MSG_PVS_R        6    // Reliable to PVS
#define MSG_PAS_R        7    // Reliable to PAS
#define MSG_ONE_UNRELIABLE    8    // Send to one client, but don't put in reliable stream, put in unreliable datagram (could be dropped)
#define MSG_SPEC        9    // Sends to all spectator proxies 
Would it only be needed arround MSG_ONE type messages?
__________________
http://www.yaur.com -=[Yaur]=- Clan Website
taheri6 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 11:01.


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