Raised This Month: $ Target: $400
 0% 

score hostname error - Help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Michell
Member
Join Date: Oct 2015
Old 11-11-2015 , 15:23   score hostname error - Help
Reply With Quote #1

Can anyone help me? the hostname is not changing


PHP Code:
new gOriginalHostName[99]
new 
gOriginalHostNameV2[99]
new 
vHostName,sHostName[99
PHP Code:
public plugin_init(){
set_task(30.0,"CheckHostName")

PHP Code:
public CheckHostName(){
       
        
get_cvar_string("hostname",gOriginalHostName,98)
       
        
gOriginalHostName gOriginalHostNameV2
       
        
if(strlen(gOriginalHostName))
        {
                
gOriginalHostName sHostName
               
                PlacarHostName
()
                
set_task(1.0,"PlacarHostName",_,_,_,"b")
        }
       

PHP Code:
public PlacarHostName(){
       
        static 
NewHostName[100]
       
        if(
strlen(gOriginalHostName)){
                if(
iLive){
                        if(
iTMD3 || iSMD3){
                                switch( 
Tempo ) {
                                        case 
0: return
                                                case 
1formatex(NewHostName,99,"%s [ MD3 1 ][ CT: %d TR: %d ] R: %d",gOriginalHostName,iMD3] + iPonto],iMD3] + iPonto],Rounds)                         //formatex(NewHostName,63,"%s T:%d] R:%d [TR: %d | CT: %d]",gOriginalHostName,Tempo,Rounds,iPrim[ 0 ] + iPonto[ 0 ],iPrim[ 1 ] + iPonto[ 1 ])
                                                
case 2formatex(NewHostName,99,"%s [ MD3 2 ][ CT: %d TR: %d ] R: %d",gOriginalHostName,iMD32] + iPonto],iMD32] + iPonto],Rounds)                               //formatex(NewHostName,63,"%s T:%d] R:%d [TR: %d | CT: %d]",gOriginalHostName,Tempo,Rounds,iPrim[ 0 ] + iPonto[ 0 ],iPrim[ 1 ] + iPonto[ 1 ])
                                        
}
                        }
                        if(
iNorT){
                                switch( 
Tempo ){
                                        case 
0:  return
                                                case 
1formatex(NewHostName,99,"%s [ 1 ][ CT: %d TR: %d ] R: %d",gOriginalHostName,iPrim] + iPonto],iPrim] + iPonto],Rounds)                           //formatex(NewHostName,63,"%s T:%d] R:%d [TR: %d | CT: %d]",gOriginalHostName,Tempo,Rounds,iPrim[ 0 ] + iPonto[ 0 ],iPrim[ 1 ] + iPonto[ 1 ])
                                                
case 2formatex(NewHostName,99,"%s [ 2 ][ CT: %d TR: %d ] R: %d",gOriginalHostName,iPrim] + iPonto],iPrim] + iPonto],Rounds)                           //formatex(NewHostName,63,"%s T:%d] R:%d [TR: %d | CT: %d]",gOriginalHostName,Tempo,Rounds,iPrim[ 0 ] + iPonto[ 0 ],iPrim[ 1 ] + iPonto[ 1 ])
                                        
}
                        }
                        else if(
iOvT){
                                switch( 
Tempo ){
                                        case 
0: return
                                                case 
1formatex(NewHostName,99,"%s [ 1 OT ][CT: %d TR: %d] R: %d",gOriginalHostName,iOver] + iPonto],iOver] + iPonto],Rounds)
                                                case 
2formatex(NewHostName,99,"%s [ 2 OT ][CT: %d TR: %d] R: %d",gOriginalHostName,iOver] + iPonto],iOver] + iPonto],Rounds)
                                        }
                        }
                }
                else{
                        
formatex(NewHostName,99,"%s",gOriginalHostNameV2)
                }
               
                
set_cvar_string("hostname",NewHostName)
        }


Last edited by Michell; 11-11-2015 at 15:32.
Michell is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-11-2015 , 19:56   Re: score hostname error - Help
Reply With Quote #2

IIRC, you have to reconnect to see the new hostname on the scoreboard. The hostname on the Steam servers list will change accurately.
__________________
fysiks 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 18:15.


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