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

[NMRIH] Empty map rotator


Post New Thread Reply   
 
Thread Tools Display Modes
Author
SilverPeak
Junior Member
Join Date: May 2016
Plugin ID:
5192
Plugin Version:
2
Plugin Category:
General Purpose
Plugin Game:
No More Room in Hell
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    keep rotating through maps at a preset time interval until a player joined
    Old 05-19-2016 , 09:01   [NMRIH] Empty map rotator
    Reply With Quote #1

    Hi,

    While im still very new to coding sourcemod plugins i end up creating alot of stuff for my own server. i'll try to share anything that might be of use to anyone else.

    What will this plugin do?

    it will by default force a map change in your server every ~8 minutes if no players are connected to it. you can define the time interval with emptyrotate_time cvar. if you do change the default cvar value of 500.0 (~8 minutes) make sure you do it in the server.cfg file and not while the server is already running the plugin.

    Why?

    by default nmrih servers keep running the last played map until it has been changed by a player vote or server admin. this means that whenever people leave your server the server will be stuck at the last played map, this usually is a map that isn't too popular with people.
    this plugin will keep rotating maps in attempt of attracting people to your server, this will really help if your server runs alot of custom maps.

    Important

    this plugin will change maps to whatever sm_nextmap defines, it does not read your mapcycle file.
    you should activate sourcemod's randomcycle.smx plugin for the intended result.
    you can find randomcycle.smx in addons/sourcemod/plugins/disabled

    Install instruction:
    drop nmrih_emptyrotate_fix.smx in addons/sourcemod/plugins/ folder and it will work. additionally you could configure the emptyrotate_time cvar, this is not required.
    Attached Files
    File Type: smx nmrih_emptyrotate_fix.smx (3.9 KB, 411 views)
    File Type: sp Get Plugin or Get Source (nmrih_emptyrotate_fix.sp - 1100 views - 874 Bytes)

    Last edited by SilverPeak; 05-28-2016 at 08:36. Reason: plugin update
    SilverPeak is offline
    mazdarx8
    Veteran Member
    Join Date: Aug 2014
    Old 05-19-2016 , 09:08   Re: [NMRIH] Empty map rotator
    Reply With Quote #2

    Hey, is it possible to add the function that I give a map in a .txt file which should be played, when server is empty?
    Because I know some maps where people would join, because the map is popular.

    Thank you.
    mazdarx8 is offline
    SilverPeak
    Junior Member
    Join Date: May 2016
    Old 05-19-2016 , 09:14   Re: [NMRIH] Empty map rotator
    Reply With Quote #3

    Quote:
    Originally Posted by mazdarx8 View Post
    Hey, is it possible to add the function that I give a map in a .txt file which should be played, when server is empty?
    Because I know some maps where people would join, because the map is popular.

    Thank you.
    Hi,

    Activate randomcycle.smx and edit what maplist randomcycle uses in addons/sourcemod/configs/maplists.cfg
    i have it currently at:

    "randomcycle"
    {
    "file" "cfg/mapcycle.txt"
    }

    i hope it helps.
    SilverPeak is offline
    yomox9
    Member
    Join Date: Jan 2014
    Location: jp
    Old 05-20-2016 , 08:00   Re: [NMRIH] Empty map rotator
    Reply With Quote #4

    Good practical script
    yomox9 is offline
    yomox9
    Member
    Join Date: Jan 2014
    Location: jp
    Old 05-21-2016 , 22:18   Re: [NMRIH] Empty map rotator
    Reply With Quote #5

    I used this script. My server often crashes when it was changed map by plugin...

    FYI.
    So I edited this script.
    I changed command from "ForceChangeLevel" to "ServerCommandEx" with changelevel_next.
    My server don't crashe now. But I don't know cause....
    https://drive.google.com/open?id=0B3...zktRzVyYzJxQTg
    yomox9 is offline
    SilverPeak
    Junior Member
    Join Date: May 2016
    Old 05-22-2016 , 17:19   Re: [NMRIH] Empty map rotator
    Reply With Quote #6

    Quote:
    Originally Posted by yomox9 View Post
    I used this script. My server often crashes when it was changed map by plugin...

    FYI.
    So I edited this script.
    I changed command from "ForceChangeLevel" to "ServerCommandEx" with changelevel_next.
    My server don't crashe now. But I don't know cause....
    https://drive.google.com/open?id=0B3...zktRzVyYzJxQTg
    Hi.

    That is strange. I have not had any error logs or crashes coming in while running this plugin on my own server.
    Maybe a third-party server plugin or map is causing a conflict? i have played at one of your servers recently and it crashed out of nowhere. there appear to be some instability issues on your server 120.143.49.171:28018.

    If you could be so kind to post any error logs regarding the crash, it would help alot with identifying the problem.

    Thank you.
    SilverPeak is offline
    SilverPeak
    Junior Member
    Join Date: May 2016
    Old 05-28-2016 , 08:38   Re: [NMRIH] Empty map rotator
    Reply With Quote #7

    plugin updated.
    SilverPeak is offline
    yomox9
    Member
    Join Date: Jan 2014
    Location: jp
    Old 06-01-2016 , 03:19   Re: [NMRIH] Empty map rotator
    Reply With Quote #8

    Quote:
    Originally Posted by SilverPeak View Post
    plugin updated.
    What is different between current version and before version?
    Maybe you should write version history(change history).
    yomox9 is offline
    SilverPeak
    Junior Member
    Join Date: May 2016
    Old 06-01-2016 , 09:44   Re: [NMRIH] Empty map rotator
    Reply With Quote #9

    Quote:
    Originally Posted by yomox9 View Post
    What is different between current version and before version?
    Maybe you should write version history(change history).
    previous version was using ForceChangeLevel sourcemod function to change map, i have replaced this method because it caused problems on my server.
    i noticed that while running this plugin for many days my server became stuck at one map and wont ever change! this is fixed in the new updated version.

    Last edited by SilverPeak; 06-01-2016 at 09:46. Reason: grammar fix
    SilverPeak is offline
    yomox9
    Member
    Join Date: Jan 2014
    Location: jp
    Old 06-01-2016 , 18:13   Re: [NMRIH] Empty map rotator
    Reply With Quote #10

    GJ. I using it in my servers.
    yomox9 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 06:38.


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