# Set Next Map

Grammar — Set the next map to map|Map File
FlagsNative | Action

Sets the next map to be run after current map finishes. Only supported in single player offline games. Use Online Map To Map Load for multiplayer map to map loading.

# Arguments

  • string — Map

Returns — void

native void GameSetNextMap(string inMap);

Category: Game / Transitions

# Examples

campaigns/liberty.sc2campaignbase.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:24586

    TriggerEnable(TriggerGetCurrent(), false);
    if ((EventCustomDialogResult() == libNtve_ge_CustomDialogResult_c_customDialogResultYes)) {
        GameSetNextMap("");
        UISetFrameVisible(PlayerGroupAll(), c_syncFrameTypePlanetPanel, false);
        GameOver(1, c_gameOverVictory, false, false);

campaigns/liberty.sc2campaignbase.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25523

    if ((libCamp_gf_MissionStatusCheck(libCamp_ge_MapID_MapTValerian03, libCamp_ge_MissionStatus_Completed) == true)) {
        UISetFrameVisible(PlayerGroupAll(), c_syncFrameTypeBattleReportPanel, true);
        GameSetNextMap("");
        GameOver(1, c_gameOverVictory, false, false);
    }

campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2mapMapScript.galaxy:24586

    TriggerEnable(TriggerGetCurrent(), false);
    if ((EventCustomDialogResult() == libNtve_ge_CustomDialogResult_c_customDialogResultYes)) {
        GameSetNextMap("");
        UISetFrameVisible(PlayerGroupAll(), c_syncFrameTypePlanetPanel, false);
        GameOver(1, c_gameOverVictory, false, false);

campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2mapMapScript.galaxy:25523

    if ((libCamp_gf_MissionStatusCheck(libCamp_ge_MapID_MapTValerian03, libCamp_ge_MissionStatus_Completed) == true)) {
        UISetFrameVisible(PlayerGroupAll(), c_syncFrameTypeBattleReportPanel, true);
        GameSetNextMap("");
        GameOver(1, c_gameOverVictory, false, false);
    }

campaigns/libertystory.sc2campaignbase.sc2data/TriggerLibs/CampaignLib.galaxy:8356


    libCamp_gf_TS_SaveAllTransitionData((lp_nextIsSimulation == true), lp_nextIsVictoryPlayAgain, false);
    GameSetNextMap(("Campaign/" + libCamp_gv_tS_MapFile[(lp_nextMission)]));
    libCamp_gf_TS_PrepareForMissionLoadingScreen(lp_nextMission, false);
}

campaigns/libertystory.sc2campaignbase.sc2data/TriggerLibs/CampaignLib.galaxy:8471

    libCamp_gf_TS_SaveAllTransitionData(false, false, (lp_resultFromVictory == c_gameOverDefeat));
    lv_mapID = libCamp_ge_MapID_MapTStory01;
    GameSetNextMap(("Campaign/" + libCamp_gv_tS_MapFile[lv_mapID]));
}

campaigns/libertystory.sc2campaignbase.sc2data/TriggerLibs/CampaignLib.galaxy:10249

    CinematicFade(false, 0.5, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
    if ((libCamp_gv_tSX_IsSimulation == false)) {
        GameSetNextMap("");
    }

campaigns/libertystory.sc2campaignbase.sc2data/TriggerLibs/CampaignLib.galaxy:12104


    libCamp_gf_ZS_CloseCampaignTrialDialog();
    GameSetNextMap("");
    GameOver(1, c_gameOverVictory, false, false);
    return true;

campaigns/swarmstory.sc2campaignbase.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:12803

    libSwaC_gf_ZS_PrepareLoadingScreen(lp_nextMission, false);
    if ((libSwaC_gf_StoryMapTypeCheck(lp_nextMission, c_mapKindUpgrade) == true)) {
        GameSetNextMap(("Campaign/Swarm/Evolution/" + libSwaC_gf_StoryMapFile(lp_nextMission)));
    }
    else {

campaigns/swarmstory.sc2campaignbase.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:12806

    }
    else {
        GameSetNextMap(("Campaign/Swarm/" + libSwaC_gf_StoryMapFile(lp_nextMission)));
    }
}

campaigns/swarmstory.sc2campaignbase.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:12837

    libSwaC_gf_ZS_SaveAllTransitionData(false, false, (lp_victoryDefeat == c_gameOverDefeat));
    libSwaC_gf_ZS_PrepareLoadingScreen(lv_nextMap, false);
    GameSetNextMap(("Campaign/Swarm/" + libSwaC_gf_StoryMapFile(lv_nextMap)));
    TextExpressionSetToken("Param/Expression/lib_SwaC_CEE1F9DE", "A", StringToText(("Campaign/Swarm/" + libSwaC_gf_StoryMapFile(lv_nextMap))));
    TriggerDebugOutput(1, TextExpressionAssemble("Param/Expression/lib_SwaC_CEE1F9DE"), false);

campaigns/swarmstory.sc2campaignbase.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:12853

    libSwaC_gf_ZS_SaveAllTransitionData(false, false, false);
    libSwaC_gf_ZS_PrepareLoadingScreen(lp_nextMap, false);
    GameSetNextMap(("Campaign/Swarm/" + libSwaC_gf_StoryMapFile(lp_nextMap)));
}

campaigns/swarmstory.sc2campaignbase.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:14126

    CinematicFade(false, 0.5, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
    if ((libSwaC_gv_zSX_IsSimulation == false)) {
        GameSetNextMap("");
    }

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignLib.galaxy:6675

    libVoiC_gf_PS_SaveAllTransitionData(lp_nextIsSimulation, lp_nextIsVictoryAgain, false);
    libVoiC_gf_PC_PrepareLoadingScreen(lp_nextMission, false);
    GameSetNextMap(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lp_nextMission)));
}

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignLib.galaxy:6708

    libVoiC_gf_PS_SaveAllTransitionData(false, false, (lp_victoryDefeat == c_gameOverDefeat));
    libVoiC_gf_PC_PrepareLoadingScreen(lv_nextMap, false);
    GameSetNextMap(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lv_nextMap)));
    TextExpressionSetToken("Param/Expression/lib_VoiC_02626E2A", "A", StringToText(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lv_nextMap))));
    TriggerDebugOutput(1, TextExpressionAssemble("Param/Expression/lib_VoiC_02626E2A"), false);

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignLib.galaxy:6754

    if ((libVoiC_gf_PC_DebugProgressDialogOpened() == false)) {
        libVoiC_gf_PC_UpdateCampaignScreen(lp_nextMap);
        GameSetNextMap(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lp_nextMap)));
        GameSetTransitionMap(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lp_nextMap)));
        TextExpressionSetToken("Param/Expression/lib_VoiC_37BD8C51", "A", libVoiC_gf_PC_CampaignMapName(lp_nextMap));

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:1475

    CinematicFade(false, 0.5, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
    if ((libVoiC_gv_pCX_IsSimulation == false)) {
        GameSetNextMap("");
    }

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:1502

    CinematicFade(false, 0.1, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
    if ((libVoiC_gv_pCX_IsSimulation == false)) {
        GameSetNextMap("");
        CampaignProgressDeleteCampaignSave(PlayerGroupAll());
    }

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:6971

    }

    GameSetNextMap("");
    GameOver(1, c_gameOverVictory, false, false);
    return true;

mods/missionpacks/campaigncommon.sc2modbase.sc2data/LibComC.galaxy:2912

    libComC_gf_NC_PrepareLoadingScreen(lp_nextMission, false);
    libComC_gf_CC_EventDispatch(libComC_ge_CC_Event_CC_EventMapTransition, (lp_nextMission), "", true);
    GameSetNextMap((libComC_gv_cC_MapPath + libComC_gf_CC_MapFile(lp_nextMission)));
}

mods/missionpacks/campaigncommon.sc2modbase.sc2data/LibComC.galaxy:2939

    libComC_gf_NS_SaveAllTransitionData(false, false, (lp_victoryDefeat == c_gameOverDefeat));
    libComC_gf_NC_PrepareLoadingScreen(libComC_gv_cC_TransitionNextMap, false);
    GameSetNextMap((libComC_gv_cC_MapPath + libComC_gf_CC_MapFile(libComC_gv_cC_TransitionNextMap)));
    TextExpressionSetToken("Param/Expression/lib_ComC_7A0F7081", "A", StringToText((libComC_gv_cC_MapPath + libComC_gf_CC_MapFile(libComC_gv_cC_TransitionNextMap))));
    TriggerDebugOutput(1, TextExpressionAssemble("Param/Expression/lib_ComC_7A0F7081"), false);

mods/missionpacks/novacampaign.sc2modbase.sc2data/LibNCMI.galaxy:2302

    }
    if ((libComC_gf_CC_TransitionInSimulation() == false)) {
        GameSetNextMap("");
    }

mods/missionpacks/novacampaign.sc2modbase.sc2data/LibNCMI.galaxy:6042

    }

    GameSetNextMap("");
    GameOver(1, c_gameOverVictory, false, false);
    return true;

mods/missionpacks/novacampaign.sc2modbase.sc2data/LibNovC.galaxy:2456

    Wait(0.0625, c_timeGame);
    DialogControlSetVisible(libNovC_gv_resultsDialog, PlayerGroupAll(), false);
    GameSetNextMap("");
    TriggerEnable(libNovC_gt_QuitDemo, true);
    UIShowCustomDialog(PlayerGroupAll(), libNtve_ge_CustomDialogType_c_customDialogTypeMessage, StringExternal("Param/Value/lib_NovC_F558D81E"), null, true);

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:5948

    libA3DDD02B_gf_PP_SaveAllTransitionData(lp_nextIsSimulation, lp_nextIsVictoryAgain, false);
    if ((lp_nextMission == "")) {
        GameSetNextMap("");
        return ;
    }

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:5953


    libA3DDD02B_gf_PP_PrepareLoadingScreen(lp_nextMission, false);
    GameSetNextMap(("Campaign/VoidPrologue/" + libA3DDD02B_gf_StoryMapFile(lp_nextMission)));
}

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:5981

    libA3DDD02B_gf_PP_SaveAllTransitionData(false, false, (lp_victoryDefeat == c_gameOverDefeat));
    libA3DDD02B_gf_PP_PrepareLoadingScreen(lv_nextMap, false);
    GameSetNextMap(("Campaign/VoidPrologue/" + libA3DDD02B_gf_StoryMapFile(lv_nextMap)));
    TextExpressionSetToken("Param/Expression/lib_A3DDD02B_CEE1F9DE", "A", StringToText(("Campaign/Swarm/" + libA3DDD02B_gf_StoryMapFile(lv_nextMap))));
    TriggerDebugOutput(1, TextExpressionAssemble("Param/Expression/lib_A3DDD02B_CEE1F9DE"), false);

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:5996

    libA3DDD02B_gf_PP_SaveAllTransitionData(false, false, false);
    libA3DDD02B_gf_PP_PrepareLoadingScreen(lp_nextMap, false);
    GameSetNextMap(("Campaign/Swarm/" + libA3DDD02B_gf_StoryMapFile(lp_nextMap)));
}

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:6952

    TriggerDebugOutput(1, StringExternal("Param/Value/lib_A3DDD02B_6C9FA21E"), false);
    if ((libA3DDD02B_gv_pPX_IsSimulation == false)) {
        GameSetNextMap("");
    }

mods/voidprologue.sc2modbase.sc2data/LibA3DDD02B.galaxy:9140

    DialogControlSetEnabled(libA3DDD02B_gv_pP_MLLaunchButton, PlayerGroupAll(), false);
    libA3DDD02B_gf_CinematicFade(false, 0.5, Color(0.00, 0.00, 0.00), true);
    GameSetNextMap("");
    GameOver(1, c_gameOverVictory, false, false);
    return true;