AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Host_Error (https://forums.alliedmods.net/showthread.php?t=192807)

DoviuX 08-14-2012 09:06

Host_Error
 
What could couse this problem ? Host_Error: WriteDest_Parm: not a client

YamiKaitou 08-14-2012 09:13

Re: Host_Error
 
Non-Steam?

DoviuX 08-14-2012 09:14

Re: Host_Error
 
Solution at the bottom

Arkshine 08-14-2012 09:16

Re: Host_Error
 
Make sure you check player is connected [and alive] before sending game message.

DoviuX 08-14-2012 09:26

Re: Host_Error
 
PHP Code:

public advert_author( ) {
        
color_print0"%s %s by %s"PREFIXPLUGINAUTHOR );
        
color_print0"%s If you wan't to turn off auto weapons type !g/auto_off!y."PREFIX );


To this and works -->

PHP Code:

    
public advert_author( ) {
    new 
players32 ], inumi;
    
get_playersplayersinum )
    for( 
0inumi++ ) {
        if( 
is_user_connected) ) {
            
color_printi"%s %s by %s"PREFIXPLUGINAUTHOR );
            
color_printi"%s If you wan't to turn off auto weapons type !g/auto_off!y."PREFIX );
        }
    }



Arkshine 08-14-2012 09:47

Re: Host_Error
 
if( is_user_connected( i ) ) { is useless, it's done already with get_players().

ConnorMcLeod 08-14-2012 09:50

Re: Host_Error
 
You don't use get_players result properly, please search on forum.

DoviuX 08-14-2012 10:06

Re: Host_Error
 
Like this ?

PHP Code:

public advert_author( ) {
    new 
players32 ], inumi;
    
get_playersplayersinum"c" 
    for( 
0inumi++ ) {
        
color_printplayers], "%s %s by %s"PREFIXPLUGINAUTHOR );
        
color_printplayers], "%s If you wan't to turn off auto weapons type !g/auto_off!y."PREFIX );
    }



ConnorMcLeod 08-14-2012 10:08

Re: Host_Error
 
Yes, but don't re-index array, read wiki plugins optimization part.


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

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