Raised This Month: $ Target: $400
 0% 

HELP - HOSTNAME


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 04-22-2012 , 18:33   HELP - HOSTNAME
Reply With Quote #1

how can i change hostname without restart/changing map? Thanks.
__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
kramesa
Veteran Member
Join Date: Feb 2011
Location: Brazil
Old 04-22-2012 , 18:35   Re: HELP - HOSTNAME
Reply With Quote #2

rcon hostname "Name"

oO
__________________
kramesa is offline
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 04-22-2012 , 18:38   Re: HELP - HOSTNAME
Reply With Quote #3

With that i need to change map or restart server..
__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
kramesa
Veteran Member
Join Date: Feb 2011
Location: Brazil
Old 04-22-2012 , 18:44   Re: HELP - HOSTNAME
Reply With Quote #4

Quote:
Originally Posted by quark View Post
With that i need to change map or restart server..
Search... This is already made.
__________________
kramesa is offline
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
Old 04-22-2012 , 18:45   Re: HELP - HOSTNAME
Reply With Quote #5

Quote:
Originally Posted by quark View Post
With that i need to change map or restart server..
No you don't. It changes the hostname, but if you're in the server and press TAB, it is still going to show the old hostname. However, if people see your server in the master list, they will see the updated hostname displayed. If you want it to change for the people that are already in the server, I believe you can send a ServerName message or something like that to have it updated.
__________________
Quote:
Originally Posted by DarkGod View Post
nikhilgupta generates his plugins using sheer awesome.
If you like my work, please
nikhilgupta345 is offline
Send a message via ICQ to nikhilgupta345 Send a message via Yahoo to nikhilgupta345
kramesa
Veteran Member
Join Date: Feb 2011
Location: Brazil
Old 04-22-2012 , 18:46   Re: HELP - HOSTNAME
Reply With Quote #6

Code:
#include < amxmodx > #include < amxmisc > new g_pHostName, g_iMsgServerName; public plugin_init( ) {     register_plugin( "amx_hostname", "1.0", "xPaw" );         register_clcmd( "amx_hostname", "CmdHostName", ADMIN_CFG, "<hostname>" );         g_iMsgServerName = get_user_msgid( "ServerName" );     g_pHostName      = get_cvar_pointer( "hostname" ); } public CmdHostName( const id, const iLevel, const iCid ) {     if( !cmd_access( id, iLevel, iCid, 1 ) )         return PLUGIN_HANDLED;         new szHostName[ 64 ];         if( read_argc( ) == 1 ) {         console_print( id, "[AMXX] Hostname has been updated." );                 get_pcvar_string( g_pHostName, szHostName, 63 );     } else {         read_argv( 1, szHostName, 63 );                 set_pcvar_string( g_pHostName, szHostName );                 console_print( id, "[AMXX] You have set hostname to ^"%s^".", szHostName );     }         message_begin( MSG_BROADCAST, g_iMsgServerName );     write_string( szHostName );     message_end( );         return PLUGIN_HANDLED; }
__________________
kramesa is offline
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 04-22-2012 , 18:46   Re: HELP - HOSTNAME
Reply With Quote #7

Quote:
Originally Posted by nikhilgupta345 View Post
No you don't. It changes the hostname, but if you're in the server and press TAB, it is still going to show the old hostname. However, if people see your server in the master list, they will see the updated hostname displayed. If you want it to change for the people that are already in the server, I believe you can send a ServerName message or something like that to have it updated.
Thanks !
__________________

Check out My Plugins:
qServerInfo ; ASKTAG
quark is offline
quark
Veteran Member
Join Date: Oct 2011
Location: Your mind.
Old 04-22-2012 , 18:48   Re: HELP - HOSTNAME
Reply With Quote #8

Quote:
Originally Posted by kramesa View Post
Code:
#include < amxmodx > #include < amxmisc > new g_pHostName, g_iMsgServerName; public plugin_init( ) {  register_plugin( "amx_hostname", "1.0", "xPaw" );    register_clcmd( "amx_hostname", "CmdHostName", ADMIN_CFG, "<hostname>" );    g_iMsgServerName = get_user_msgid( "ServerName" );  g_pHostName      = get_cvar_pointer( "hostname" ); } public CmdHostName( const id, const iLevel, const iCid ) {  if( !cmd_access( id, iLevel, iCid, 1 ) )   return PLUGIN_HANDLED;    new szHostName[ 64 ];    if( read_argc( ) == 1 ) {   console_print( id, "[AMXX] Hostname has been updated." );     get_pcvar_string( g_pHostName, szHostName, 63 );  } else {   read_argv( 1, szHostName, 63 );     set_pcvar_string( g_pHostName, szHostName );     console_print( id, "[AMXX] You have set hostname to ^"%s^".", szHostName );  }    message_begin( MSG_BROADCAST, g_iMsgServerName );  write_string( szHostName );  message_end( );    return PLUGIN_HANDLED; }
Oh, thanks kramesa. I will check it later

EDIT Sorry for double
__________________

Check out My Plugins:
qServerInfo ; ASKTAG

Last edited by quark; 04-22-2012 at 18:48.
quark is offline
NeedYourHelp
Member
Join Date: Dec 2011
Old 04-23-2012 , 07:11   Re: HELP - HOSTNAME
Reply With Quote #9

amx_rcon hostname "Name"
or
admin_rcon hostname "Name"
NeedYourHelp is offline
Reply


Thread Tools
Display Modes

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 07:53.


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