Raised This Month: $ Target: $400
 0% 

[L4D2] Automatic Campaign Switcher (ACS) [v2.0.0 (Nov 16, 2021)] - OVERHAULED!


Post New Thread Reply   
 
Thread Tools Display Modes
Author
rikka0w0
Member
Join Date: May 2018
Location: Sydney, Australia / Beij
Plugin ID:
2325
Plugin Version:
v2.0.0
Plugin Category:
General Purpose
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
    216 
    Plugin Description:
    Automatically switches to the next campaign when the current campaign is complete
    Old 06-27-2018 , 09:01   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #1

    After a few hours of coding i finally made it! Now the maplist.txt is automatically managed by the plugin. Maplist.txt only controls the order of mapcycle, localization text files are moved to the translation folder.

    New Feature:
    1. If theres no maplist.txt existed, the plugin will generate one with default configuration, it will scan for both official maps and 3rd maps.
    2. If one or more map are added to the server, the plugin will automatically append it to the end of maplist.txt
    3. If one or more map are removed from the server, the plugin will show their name in the server console.
    4. Provides better localization, localized map voting system, supports multi language.

    Code:
    sm plugins load acs
    MapCycle=addons\sourcemod\configs\maplist.txt
    Num of Campaign=13, 17
    0=Dead Center (L4D2C1)
    1=Dark Carnival (L4D2C2)
    2=Swamp Fever (L4D2C3)
    3=Hard Rain (L4D2C4)
    4=The Parish (L4D2C5)
    5=The Passing (L4D2C6)
    6=The Sacrifice (L4D2C7)
    7=No Mercy (L4D2C8)
    8=Crash Course (L4D2C9)
    9=Death Toll (L4D2C10)
    10=Dead Air (L4D2C11)
    11=Blood Harvest (L4D2C12)
    12=Cold Stream (L4D2C13)
    13=CrashBandicoot (CrashBandicootTheReturn)
    14=CrashBandicoot2 (l4d2CrashBandicoot2)
    15=Questionable Ethics 2 (QuestionableEthicsAlphaTest)
    16=Questionable Ethics 1 (QuestionableEthics)
    [SM] Loaded plugin acs.smx successfully.
    Num of Campaign=13, 17 :
    13 maps are in cycle, 17 maps available. The after finishing any of the first 13 maps, the server will change to next map. After finishing the 13th map it will jump to the first map. The last 4 maps are 3rd maps, finishing any of them will jump to the first map.


    Up to now, the Scavenge mode map list is still hard coded. The coop mode map list is managed by the plugin. The plugin looks for translated texts in the client's language first, if failed then attempt using English, if such English text does not exists, use the map name itself.
    Attached Files
    File Type: txt maps.phrases.txt (804 Bytes, 211 views)
    File Type: txt acs.phrases.txt (465 Bytes, 236 views)
    File Type: sp Get Plugin or Get Source (acs.sp - 482 views - 70.0 KB)

    Last edited by rikka0w0; 06-28-2018 at 14:06.
    rikka0w0 is offline
    Mr. Man
    Veteran Member
    Join Date: Mar 2011
    Location: Huh?
    Old 06-27-2018 , 13:49   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #2

    Nice breakthrough - was always a pain having to recompile to add that one additional map. Good luck!
    Mr. Man is offline
    rikka0w0
    Member
    Join Date: May 2018
    Location: Sydney, Australia / Beij
    Old 07-15-2018 , 11:55   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #3

    Try my new plugin: Improved ACS, which is based on this version and also the successor
    Modification to SP files is no longer required!
    The plugin can find both official and addon campaigns automatically
    Also fixed number of bugs in this plugin
    __________________
    rikka0w0 is offline
    Mi.Cura
    Veteran Member
    Join Date: Dec 2016
    Location: Brazil
    Old 09-25-2018 , 16:28   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.3 (May 21, 2011)]
    Reply With Quote #4

    I've always used the ACS 1.2.3_Kruffty version.

    https://forums.alliedmods.net/showpo...&postcount=154

    And last year I had a problem that the Blood Harvest campaign did not open the vote at the end of the map.
    With the (MasterMind420) hint I corrected the initial letter of the final map from c12m5_cornfield to C12m5_cornfield in the .sp file and this corrected the problem.

    But now the problem has returned, and sometimes the vote does not open at the end of this campaign.

    Someone know of some functional version. I do not know if this is caused by valve update, I'm not sure.

    Do you know of any functional version?

    I also tested the new version 1.9 but it does not work in several campaigns.
    https://forums.alliedmods.net/showthread.php?t=308708

    Could someone help?
    __________________
    Mi.Cura | Modded Servers | L4D2
    https://steamcommunity.com/groups/micuramodzombie
    Mi.Cura is offline
    Lux
    Veteran Member
    Join Date: Jan 2015
    Location: Cat
    Old 09-25-2018 , 16:52   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.3 (May 21, 2011)]
    Reply With Quote #5

    Quote:
    Originally Posted by Mi.Cura View Post
    I've always used the ACS 1.2.3_Kruffty version.

    https://forums.alliedmods.net/showpo...&postcount=154

    And last year I had a problem that the Blood Harvest campaign did not open the vote at the end of the map.
    With the (MasterMind420) hint I corrected the initial letter of the final map from c12m5_cornfield to C12m5_cornfield in the .sp file and this corrected the problem.

    But now the problem has returned, and sometimes the vote does not open at the end of this campaign.

    Someone know of some functional version. I do not know if this is caused by valve update, I'm not sure.

    Do you know of any functional version?

    I also tested the new version 1.9 but it does not work in several campaigns.
    https://forums.alliedmods.net/showthread.php?t=308708

    Could someone help?
    Just turn off case sensitive in the map name checking
    __________________
    Connect
    My Plugins: KlickME
    [My GitHub]

    Commission me for L4D
    Lux is offline
    Mi.Cura
    Veteran Member
    Join Date: Dec 2016
    Location: Brazil
    Old 09-25-2018 , 17:04   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.3 (May 21, 2011)]
    Reply With Quote #6

    Quote:
    Originally Posted by Lux View Post
    Just turn off case sensitive in the map name checking
    Hello Lux,

    It's to change the .sp, right?

    Can you help me which line to change? What's the command?

    I do not know how to do that.
    __________________
    Mi.Cura | Modded Servers | L4D2
    https://steamcommunity.com/groups/micuramodzombie

    Last edited by Mi.Cura; 09-25-2018 at 17:11.
    Mi.Cura is offline
    Psyk0tik
    Veteran Member
    Join Date: May 2012
    Location: Homeless
    Old 09-25-2018 , 17:20   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.3 (May 21, 2011)]
    Reply With Quote #7

    Quote:
    Originally Posted by Mi.Cura View Post
    Hello Lux,

    It's to change the .sp, right?

    Can you help me which line to change? What's the command?

    I do not know how to do that.
    Just look for every StrEqual() line.

    If you see something like this:

    PHP Code:
    if (StrEqual(sSomethingsSomething2)) 
    Change it to this:

    PHP Code:
    if (StrEqual(sSomethingsSomething2false)) 
    In the original ACS, I modified this code:

    PHP Code:
    bool:OnFinaleOrScavengeMap()
    {
        if(
    g_iGameMode == GAMEMODE_SCAVENGE)
            return 
    true;
        if(
    g_iGameMode == GAMEMODE_SURVIVAL)
            return 
    false;
        
    decl String:strCurrentMap[32];
        
    GetCurrentMap(strCurrentMap,32);
        for(new 
    iMapIndex 0iMapIndex NUMBER_OF_CAMPAIGNSiMapIndex++)
            if(
    StrEqual(strCurrentMapg_strCampaignLastMap[iMapIndex]) == true// Modify this part...
                
    return true;
        return 
    false;

    To this:

    PHP Code:
    bool OnFinaleOrScavengeMap()
    {
        if (
    g_iGameMode == GAMEMODE_SCAVENGE)
        {
            return 
    true;
        }
        if (
    g_iGameMode == GAMEMODE_SURVIVAL)
        {
            return 
    false;
        }
        
    char sCurrentMap[32];
        
    GetCurrentMap(sCurrentMapsizeof(sCurrentMap));
        for (
    int iMapIndex 0iMapIndex NUMBER_OF_CAMPAIGNSiMapIndex++)
        {
            if (
    StrEqual(strCurrentMapg_strCampaignLastMap[iMapIndex], false)) // Added "false" for the caseSensitive parameter...
            
    {
                return 
    true;
            }
        }
        return 
    false;

    __________________
    Psyk0tik is offline
    Psyk0tik
    Veteran Member
    Join Date: May 2012
    Location: Homeless
    Old 03-28-2019 , 08:24   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #8

    So... Does anybody want a L4D1 version for this? Lol
    __________________
    Psyk0tik is offline
    MasterMind420
    BANNED
    Join Date: Nov 2010
    Old 06-15-2019 , 08:32   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #9

    The problem with all these campaign shifting plugins...they never actually deal with the ReturnToLobby call at the end of every campaign...they just try and bypass it. I'm not home at the moment but will post a fix for this when i'm home. I got tired of getting bumped out of my server so I fixed it. This afflicts every campaign changing plugin like this where it switches at the end of the campaign. ReturnToLobby sometimes gets called before the map change takes place. This issue is not Versus exclusive either...basically just prevent the ReturnToLobby UserMessage under any circumstance except actually voting to return to lobby...problem solved...

    Last edited by MasterMind420; 06-15-2019 at 08:35.
    MasterMind420 is offline
    rekcah
    Member
    Join Date: Jun 2019
    Old 06-17-2019 , 00:02   Re: [L4D2] Automatic Campaign Switcher (ACS) [v1.2.2 (May 21, 2011)]
    Reply With Quote #10

    MasterMind420, did you end up posting your solution?
    rekcah 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 21:38.


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