# Create Saved Game
Grammar — Create a saved game with name name and description description using image image and auto save set to automatic
Flags —Native
|Action
|Restricted
Creates a saved game. This action has the side effect of suspending the current trigger until the next game loop.
# Arguments
text
— Nametext
— Descriptionstring
— Imagebool
— Automatic
Returns — void
native void GameSaveCreate(
text inName,
text inDescription,
string inImage,
bool inAutomatic,
);
# Related
Category: Game / Game Settings
- Map Initialization —
void
— TriggerAddEventMapInit - Save Game Started —
void
— TriggerAddEventSaveGame - Save Game Finished —
void
— TriggerAddEventSaveGameDone - Load Game Finished —
void
— TriggerAddEventLoadGameDone - Set Game Speed —
void
— GameSetSpeedValue - Game Set Quit On Quit Button —
void
— GameSetQuitOnQuitButton - Set Global Time Scale —
void
— GameSetGlobalTimeScale - Pause Mission Time —
void
— GameSetMissionTimePaused - Mission Time Paused —
bool
— GameIsMissionTimePaused - Mission Time —
fixed
— GameGetMissionTime - Set Minimum Game Speed —
void
— GameSetSpeedValueMinimum - Lock Game Speed —
void
— GameSetSpeedLocked - Game Speed Factor —
fixed
— GameGetSpeed - Game Speed —
int
<preset::GameSpeed> — GameGetSpeedValue - Global Time Scale —
fixed
— GameGetGlobalTimeScale - Game Speed Minimum —
int
<preset::GameSpeed> — GameGetSpeedValueMinimum - Game Speed Is Locked —
bool
— GameIsSpeedLocked - Attribute Game Value —
string
<attributevalue> — GameAttributeGameValue - Attribute Player Value —
string
<attributevalue> — GameAttributePlayerValue - Players On Team —
playergroup
— GameAttributePlayersForTeam - Turn Fixed Random Seed On/Off —
void
— GameSetSeedLocked - Random Seed Is Locked —
bool
— GameIsSeedLocked - Set Random Seed —
void
— GameSetSeed - Create Saved Game —
void
— GameSaveCreate - Set Game Pausing Allowed —
void
— GameSetPauseable - Set Tradeshow Game Time Remaining —
void
— GameSetAbsoluteTimeRemaining - Pause Tradeshow Game Time Remaining —
void
— GameSetAbsoluteTimeRemainingPaused - Tradeshow Game Time Remaining —
fixed
— GameGetAbsoluteTimeRemaining - Tradeshow Game Time Remaining Is Paused —
bool
— GameGetAbsoluteTimeRemainingPaused - Map Name —
text
— GameMapName - Map Path —
string
— GameMapPath - Map Description —
text
— GameMapDescription - Map Is Blizzard —
bool
— GameMapIsBlizzard - Map Texture Set —
string
<gamelink::Terrain> — GameTerrainSet - Game Is Test —
bool
— GameIsTestMap - Game Is Examinable —
bool
— GameIsExaminable - Game Get Test Config Type —
int
— GameTestConfigType - Game Is Online —
bool
— GameIsOnline - Game Is Debug Option Set —
bool
— GameIsDebugOptionSet - Game Is Matchmade —
bool
— GameIsMatchmade - Game Is Competitive —
bool
— GameIsCompetitive - Game Is Practice —
bool
— GameIsPractice - Game Is Cooperative —
bool
— GameIsCooperative - Game Allows Duplicate Heroes —
bool
— GameAreHeroDuplicatesAllowed
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13869
libCamp_gf_PrepareForStoryModeTransitionalSave();
gf_TransitionalSave();
GameSaveCreate(lv_name, StringToText(""), "", true);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13869
libCamp_gf_PrepareForStoryModeTransitionalSave();
gf_TransitionalSave();
GameSaveCreate(lv_name, StringToText(""), "", true);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:799
libCamp_gv_tS_MissionAutoSaveIndex += 1;
lv_name = (libCamp_gf_MissionName(libCamp_gv_tS_CurrentMap) + StringExternal("Param/Value/lib_Camp_C21C1513"));
GameSaveCreate(lv_name, lp_description, "", true);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:9498
GameSetTransitionMap(("Campaign/" + libCamp_gv_tS_MapFile[(libCamp_ge_MapID_MapTStory01)]));
GameSaveCreate(lp_name, lp_transition, "", true);
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:3675
lv_name = TextExpressionAssemble("Param/Expression/lib_SwaC_8CBDD654");
lv_image = libSwaC_gf_StoryMapLoadingScreenImage(libSwaC_gf_CurrentMap());
GameSaveCreate(lv_name, lp_description, lv_image, true);
Wait(1.0, c_timeGame);
libSwaC_gv_zS_MissionAutoSaveDone = true;
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:12886
lv_image = libSwaC_gf_StoryMapLoadingScreenVictoryImage(libSwaC_gf_CurrentMap());
}
GameSaveCreate(lp_name, lp_transition, lv_image, true);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:684
GameSetTransitionMap(lv_transitionMap);
lv_image = libSwaC_gf_StoryMapLoadingScreenVictoryImage(libSwaC_gf_CurrentMap());
GameSaveCreate(libSwaC_gf_StoryMapName(libSwaC_gf_CurrentMap()), StringToText(""), lv_image, true);
Wait(0.1, c_timeGame);
}
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignLib.galaxy:6496
lv_image = libVoiC_gf_PC_CampaignMapLoadingScreenVictoryImage(libVoiC_gf_CurrentMap());
}
GameSaveCreate(lp_name, lp_transition, lv_image, true);
}
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignLib.galaxy:6757
GameSetTransitionMap(("Campaign/Void/" + libVoiC_gf_PC_CampaignMapFile(lp_nextMap)));
TextExpressionSetToken("Param/Expression/lib_VoiC_37BD8C51", "A", libVoiC_gf_PC_CampaignMapName(lp_nextMap));
GameSaveCreate(TextExpressionAssemble("Param/Expression/lib_VoiC_37BD8C51"), StringToText(""), "", true);
}
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:245
TextExpressionSetToken("Param/Expression/lib_VCMI_87B2D44D", "A", libVoiC_gf_PC_CampaignMapName(libVoiC_gf_CurrentMap()));
lv_name = TextExpressionAssemble("Param/Expression/lib_VCMI_87B2D44D");
GameSaveCreate(lv_name, lp_description, "", true);
Wait(1.0, c_timeGame);
libVCMI_gv_pM_MissionAutoSaveDone = true;
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignStoryLib.galaxy:974
lv_image = libVoiC_gf_PC_CampaignMapLoadingScreenVictoryImage(libVoiC_gf_CurrentMap());
TextExpressionSetToken("Param/Expression/lib_VCST_9B920DB7", "A", libVoiC_gf_StoryPlanetName(libVoiC_gf_CurrentLocation()));
GameSaveCreate(TextExpressionAssemble("Param/Expression/lib_VCST_9B920DB7"), StringToText(""), lv_image, true);
Wait(0.1, c_timeGame);
}
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/SupportLib.galaxy:7704
}
GameSaveCreate(StringExternal("Param/Value/lib_Sprt_D009FA2B"), StringExternal("Param/Value/lib_Sprt_F0890456"), "", false);
return true;
}
mods/missionpacks/campaigncommon.sc2mod — base.sc2data/LibComC.galaxy:2885
}
GameSetTransitionMap((libComC_gv_cC_MapPath + libComC_gf_CC_MapFile(libComC_gv_cC_TransitionSaveMap)));
GameSaveCreate(lp_name, lp_transition, lv_image, true);
}
mods/missionpacks/novacampaign.sc2mod — base.sc2data/LibNCMI.galaxy:1705
TextExpressionSetToken("Param/Expression/lib_NCMI_87B2D44D", "A", libComC_gf_CC_MapName(libComC_gf_CurrentMap()));
lv_name = TextExpressionAssemble("Param/Expression/lib_NCMI_87B2D44D");
GameSaveCreate(lv_name, lp_description, "", true);
Wait(1.0, c_timeGame);
libNCMI_gv_NM_MissionAutoSaveDone = true;
mods/missionpacks/novacampaign.sc2mod — base.sc2data/LibNCST.galaxy:876
lv_image = libComC_gf_CC_MapLoadingScreenVictoryImage(libComC_gf_CurrentMap());
TextExpressionSetToken("Param/Expression/lib_NCST_9B920DB7", "A", libComC_gf_CC_LocationName(libComC_gf_CurrentLocation()));
GameSaveCreate(TextExpressionAssemble("Param/Expression/lib_NCST_9B920DB7"), StringToText(""), lv_image, true);
Wait(0.1, c_timeGame);
}
mods/starcoop/starcoop.sc2mod — base.sc2data/LibCOMI.galaxy:538
TextExpressionSetToken("Param/Expression/lib_COMI_87B2D44D", "A", libCOOC_gf_CC_CampaignMapName(libCOOC_gf_CC_CurrentMap(), 1));
lv_name = TextExpressionAssemble("Param/Expression/lib_COMI_87B2D44D");
GameSaveCreate(lv_name, lp_description, "", true);
Wait(1.0, c_timeGame);
libCOMI_gv_cM_MissionAutoSaveDone = true;
mods/voidprologue.sc2mod — base.sc2data/LibA3DDD02B.galaxy:2392
lv_name = TextExpressionAssemble("Param/Expression/lib_A3DDD02B_8CBDD654");
lv_image = libA3DDD02B_gf_StoryMapLoadingScreenImage(libA3DDD02B_gf_CurrentMap());
GameSaveCreate(lv_name, lp_description, lv_image, true);
Wait(1.0, c_timeGame);
libA3DDD02B_gv_pP_MissionAutoSaveDone = true;
mods/voidprologue.sc2mod — base.sc2data/LibA3DDD02B.galaxy:6028
lv_image = libA3DDD02B_gf_StoryMapLoadingScreenVictoryImage(libA3DDD02B_gf_CurrentMap());
}
GameSaveCreate(lp_name, lp_transition, lv_image, true);
}