Raised This Month: $154 Target: $400
 38% 

[L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]


Post New Thread Reply   
 
Thread Tools Display Modes
Author
ChrisP
Member
Join Date: Jan 2010
Plugin ID:
2325
Plugin Version:
v1.2.2
Plugin Category:
General Purpose
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
    223 
    Plugin Description:
    Automatically switches to the next campaign when the previous campaign is over
    Old 05-05-2011 , 19:57   [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #1

    Automatic Campaign Switcher


    Automatic Campaign Switcher, or ACS, was written as an easy way to keep the Left4Dead 2 default map rotation going on a server without people being booted because the vote to restart a campaign was not passed. I also tried to write ACS in such a way that it would be easy to change for those who wish to edit the source to have custom campaigns and maps in l4d2 as well. If you decide not to edit the files, then ACS will cycle through maps in chronological order corresponding to the L4D story timeline. ACS also includes a voting system in which people can vote for their favorite campaign/map on a finale or scavenge map. The winning campaign/map will become the next map the server loads.


    Installation

    Just drag the .smx file into your plugin folder. Your plugin folder will likely be something like this:
    C:\Program Files (x86)\Steam\steamapps\common\left 4 dead 2\left4dead2\addons\sourcemod\plugins\

    Features of Automatic Campaign Switcher

    • ACS is easy to install, there is no messing with text files, just plug and play.
    • Voting System that allows players to vote for the next campaign/map.
    • Supports all of these game modes in L4D2:
    • coop
    • realism
    • versus
    • teamversus
    • teamscavenge
    • scavenge
    • mutation 1-20
    • community 1-5
    • Supports dynamic gamemodes, in other words, ACS will still work if the server switches to another game mode without restarting or shutting down the server.
    • Easily editable .sp file, so anyone can set up their own campaign rotation.
    • You can limit the amount of failures during a Coop campaign finale map before ACS will switch to the next campaign.


    Player Commands

    • !mapvote - Allows any player to vote and revote for the next campaign to play
    • !mapvotes - Displays to the player the current vote winner as well as all of the current votes


    Customization of Automatic Campaign Switcher

    If you choose to disable the voting system or change any other settings, you can change the cvars located in the config file. This file will likely be located in a location similar to this:
    C:\Program Files (x86)\Steam\steamapps\common\left 4 dead 2\left4dead2\cfg\sourcemod\Automatic_Campaign _Switcher_vX.X.X.cfg

    Console Variables (CVars)

    // Version of Automatic Campaign Switcher (ACS) on this server
    acs_version

    // Enables players to vote for the next map or campaign [0 = DISABLED, 1 = ENABLED]
    acs_voting_system_enabled "1"

    // Determines if a sound plays when a new map is winning the vote [0 = DISABLED, 1 = ENABLED]
    acs_voting_sound_enabled "1"

    // Sets how to advertise voting at the start of the map [0 = DISABLED, 1 = HINT TEXT, 2 = CHAT TEXT, 3 = OPEN VOTE MENU]
    acs_voting_ad_mode "1"

    // Time, in seconds, to wait after survivors leave the start area to advertise voting as defined in acs_voting_ad_mode
    acs_voting_ad_delay_time "1.0"

    // Sets how the next campaign/map is advertised during a finale or scavenge map [0 = DISABLED, 1 = HINT TEXT, 2 = CHAT TEXT]
    acs_next_map_ad_mode "1"

    // The time, in seconds, between advertisements for the next campaign/map on finales and scavenge maps
    acs_next_map_ad_interval "600.0"

    // The amount of times the survivors can fail a finale in Coop before it switches to the next campaign [0 = INFINITE FAILURES]
    acs_max_coop_finale_failures "5"


    I hope you enjoy the plugin. Remember, if you have any questions or suggestions, I will be happy to help.


    Change Log:

    v1.2.2
    • Fixed the sound to play to all the players in the game
    • Added a max amount of coop finale map failures cvar for xindong
    • Added message for new vote winner when a player disconnects
    • Changed the wait time for voting ad from round_start to the
      player_left_start_area event
    • Added the voting sound when the vote menu pops up
    v1.2.1
    • Fixed mutation 15 (Versus Survival)
    v1.2.0
    • Changed some of the text to be more clear
    • Added timed notifications for the next map
    • Added a cvar for how to advertise the next map
    • Added a cvar for the next map advertisement interval
    • Added a sound to help notify players of a new vote winner
    • Added a cvar to enable/disable sound notification
    • Added a custom wait time for coop game modes
    v1.1.0
    • Added a voting system
    • Added error checks if map is not found when switching
    • Added a cvar for enabling/disabling voting system
    • Added a cvar for how to advertise the voting system
    • Added a cvar for time to wait for voting advertisement
    • Added all current Mutation and Community game modes
    v1.0.0
    • Initial Release

    Attached Files
    File Type: sp Get Plugin or Get Source (ACS v1.2.2.sp - 9195 views - 47.0 KB)
    File Type: cfg Automatic_Campaign_Switcher_v1.2.2.cfg (1.7 KB, 5154 views)

    Last edited by ChrisP; 05-30-2011 at 20:26. Reason: Added ACS Commands
    ChrisP is offline
    JackieChan
    SourceMod Donor
    Join Date: Nov 2009
    Old 05-05-2011 , 21:05   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #2

    Nice work!

    Would it be possible to add a vote be fired at the start of the last map to choose which campaign to switch to at the end of each campaign?

    Last edited by JackieChan; 05-05-2011 at 21:09.
    JackieChan is offline
    DestructDez1
    Junior Member
    Join Date: Jan 2011
    Old 05-06-2011 , 02:32   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #3

    Fantastic job. looked for ever for something like this. FMC has too many issues and is difficult to use at times. Support for mutation12 was a dream come true when I saw this.

    Tested on 6 servers. Everything works.
    DestructDez1 is offline
    xindong
    Member
    Join Date: Dec 2010
    Old 05-10-2011 , 00:57   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #4

    Very good.
    But I hope can increase hints
    xindong is offline
    Zbeer
    SourceMod Donor
    Join Date: Aug 2010
    Old 05-10-2011 , 11:19   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #5

    Will work in mutation19?
    Zbeer is offline
    MasterMind420
    Veteran Member
    Join Date: Nov 2010
    Old 05-11-2011 , 23:26   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #6

    First of all, would just like to say U ARE THE MAN. Been looking for this for a long time. Now I do have one request and not sure if its possible. Can you make it so it doesn't switch until after the end campaign stats are shown, kinda sucks cuz I like being able to see how well I did compared to others. If not thats cool too, you still get mad props...thanks again.
    MasterMind420 is offline
    ChrisP
    Member
    Join Date: Jan 2010
    Old 05-12-2011 , 19:12   Re: [L4D2] Automatic Campaign Switcher (ACS)
    Reply With Quote #7

    Quote:
    Originally Posted by JackieChan View Post
    Nice work!

    Would it be possible to add a vote be fired at the start of the last map to choose which campaign to switch to at the end of each campaign?
    I added a voting system with some settings to configure, if you wish.

    Quote:
    Originally Posted by xindong View Post
    Very good.
    But I hope can increase hints
    I am not sure what you mean by this. Do you mean to add text to tell players that the map will automatically change? Please elaborate.

    Quote:
    Originally Posted by Zbeer View Post
    Will work in mutation19?
    I updated ACS to now work will all mutation and comminuty game modes.

    Quote:
    Originally Posted by MasterMind420 View Post
    First of all, would just like to say U ARE THE MAN. Been looking for this for a long time. Now I do have one request and not sure if its possible. Can you make it so it doesn't switch until after the end campaign stats are shown, kinda sucks cuz I like being able to see how well I did compared to others. If not thats cool too, you still get mad props...thanks again.
    I could make it so that the time to switch the map matches up with the time it takes for the statistics to scroll by, but there is a problem. If you play to the end of the campaign, you will notice that the players have the option of skipping the credits. If they do this, it will automatically send them to the lobby. I am not sure that there is a way around this. If you or anyone else has a solution, post it, and I will see if I can implement it.


    I am glad that you guys like the plugin. If there is anything else I can do to improve ACS more to your liking, let me know.
    ChrisP is offline
    JackieChan
    SourceMod Donor
    Join Date: Nov 2009
    Old 05-13-2011 , 05:34   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.1.0 (5/12/2011)]
    Reply With Quote #8

    Awesome Chris, very nice! Thanks for adding my suggestion.
    JackieChan is offline
    xindong
    Member
    Join Date: Dec 2010
    Old 05-13-2011 , 06:02   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.1.0 (5/12/2011)]
    Reply With Quote #9

    Means: in the final hurdle began hints.
    xindong is offline
    MasterMind420
    Veteran Member
    Join Date: Nov 2010
    Old 05-14-2011 , 08:56   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.1.0 (5/12/2011)]
    Reply With Quote #10

    ok so, I changed this in the sp file so that i could watch the end stats in Coop all the way through:

    #define TIME_TO_WAIT 70.0

    Could you please re-add this in the next version, i'm sticking with version 1.0.0 for now...much appreciated.
    MasterMind420 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 05:43.


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