Raised This Month: $51 Target: $400
 12% 

[L4D2] Server namer


Post New Thread Reply   
 
Thread Tools Display Modes
Author
sheo
SourceMod Donor
Join Date: Jul 2013
Location: Russia, Moscow
Plugin ID:
3886
Plugin Version:
3.2
Plugin Category:
Statistical
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
    128 
    Plugin Description:
    Changes server hostname according to the current game mode (supports Confogl)
    Old 09-08-2013 , 08:09   [L4D2] Server namer
    Reply With Quote #1

    Options available
    1) You can specify your server name that the current game mode will be added to.
    2) You can specify the server number, useful if you have many servers.
    3) You can manually edit or add game modes in external key values file, useful if you have custom mutations on your servers.
    4) You can specify the static hostname using console command at any time
    5) You can format dynamic hostname as you wish.

    ConVars
    sn_host_num "0" - set your server number here, this is usually added to launch command line.
    sn_main_name "Hostname" - set your server name here.
    sn_hostname_format1 "[{hostname} #{servernum}] {gamemode}" - choose preferable format of a hostname without difficulty levels, such as Confogl match or vanilla Versus
    sn_hostname_format2 "[{hostname} #{servernum}] {gamemode} - {difficulty}" - choose preferable format of a hostname with difficulty levels, such as Campaign
    sn_hostname_format3 "[{hostname} #{servernum}]" - choose preferable format of an emty server

    Console commands
    sn_hostname "Server name" - set your static hostname here, it wont be changed until you type sn_hostname without arguments: this will set the hostname back to dynamic.

    Installation
    Put the server_namer.smx to your plugins folder.
    Put the server_namer.txt to your configs folder.
    Don`t forget to remove hostname cvar and replace it by sn_main_name "This is my server"

    Changelog
    Spoiler
    Attached Files
    File Type: txt server_namer.txt (2.5 KB, 1987 views)
    File Type: sp Get Plugin or Get Source (server_namer.sp - 3282 views - 7.5 KB)
    __________________

    Last edited by sheo; 10-07-2014 at 12:09. Reason: Plugin update
    sheo is offline
    epilimic
    Junior Member
    Join Date: Feb 2013
    Old 10-07-2013 , 11:52   Re: [L4D2] Server namer
    Reply With Quote #2

    Hello, I'm getting this on server startup.

    L 10/07/2013 - 10:22:04: [SM] Native "HookConVarChange" reported: Invalid convar handle 0 (error 4)
    L 10/07/2013 - 10:22:04: [SM] Displaying call stack trace for plugin "server_namer.smx":
    L 10/07/2013 - 10:22:04: [SM] [0] Line 91, server_namer.sp::OnPluginStart()

    I don't have "hostname" set, I replaced it inside server.cfg with:

    sn_main_name "This server"
    sn_name_format 2

    Line 91 is a cvar check for l4d_ready_enabled.. I tried setting it as both 0 and 1 in server.cfg (with and without sm_cvar for both) and still had the same result.

    My server name is stuck as "Left 4 Dead 2" in default mode. If I forcematch to a confogl config it will change correctly, however once I resetmatch and put it back into vanilla/default mode the name changes back to "Left 4 Dead 2".

    What's going on here?

    To note:
    I'm using MM 1.10 and SM 1.6
    I've recompiled this plugin with 1.6, no change
    I've reinstalled my entire server from scratch to be sure it wasn't a bad upload, no change
    If I do "sm_cvar sn_main_name" the server will report back the correct name that I have set, yet it still appears as "Left 4 Dead 2"

    Thanks!

    Last edited by epilimic; 10-07-2013 at 11:54.
    epilimic is offline
    sheo
    SourceMod Donor
    Join Date: Jul 2013
    Location: Russia, Moscow
    Old 10-07-2013 , 23:39   Re: [L4D2] Server namer
    Reply With Quote #3

    If HookConVarChange returns this error, that means the Cvar does not exist = l4dready is not loaded. On newer versions of Confogl install created by ProMod team ReadyUp loads after match load, but is not loaded in vanilla. I will fix it asap.

    upd:
    Updated the plugin, should work fine now. Please test it and give a feedback, I don`t have Confogl on my servers

    Last edited by sheo; 10-08-2013 at 00:20. Reason: updatedplugin
    sheo is offline
    epilimic
    Junior Member
    Join Date: Feb 2013
    Old 10-08-2013 , 00:39   Re: [L4D2] Server namer
    Reply With Quote #4

    Looks good, thanks!
    epilimic is offline
    dustinandband
    Senior Member
    Join Date: May 2015
    Old 11-08-2015 , 21:22   Re: [L4D2] Server namer
    Reply With Quote #5

    My promod server seems to not pick up confogl modes, but everything else (survival, campaign, mutations, etc.) it picks up on. When I load into a confogl mode the game info will just display what it was on ("campaign - expert", for example), and won't change to something like "hunters 1v1 4.4.2."

    I couldn't find anything in the error logs that relate to this ( http://pastebin.com/LTDiNZNd ), most of the errors were spammed from a caster plugin not working correctly.
    dustinandband is offline
    sheo
    SourceMod Donor
    Join Date: Jul 2013
    Location: Russia, Moscow
    Old 11-12-2015 , 04:14   Re: [L4D2] Server namer
    Reply With Quote #6

    It is possible that Confogl devs changed the plugins keyfeatures. Please add me to Steam and we will make some testing. The profile link is given below
    upd: But first, make sure the plugin is actually loaded during Confogl enabled!!
    __________________

    Last edited by sheo; 11-12-2015 at 04:16.
    sheo is offline
    dustinandband
    Senior Member
    Join Date: May 2015
    Old 11-13-2015 , 16:47   Re: [L4D2] Server namer
    Reply With Quote #7

    Turns out I forgot to name the plugin in sharedplugins.cfg so it loads during every match. Silly mistake
    dustinandband 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 23:46.


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