# Set Data Conversation State
Grammar — Set conversation stateIndex|State to value
Flags —Native
|Action
Sets a conversation state to an integer.
# Arguments
string
<convstateindex> — State Indexint
— Value
Returns — void
native void ConversationDataStateSetValue(
string stateIndex,
int value,
);
# Related
Category: Conversation / Data Conversations
- Set Data Conversation State —
void
— ConversationDataStateSetValue - Set Data Conversation Portrait —
void
— ConversationDataRegisterPortrait - Set Data Conversation Unit —
void
— ConversationDataRegisterUnit - Set Data Conversation Camera —
void
— ConversationDataRegisterCamera - Run Data Conversation —
void
— ConversationDataRun - Stop Data Conversation —
void
— ConversationDataStop - Data Conversation State Changed —
void
— TriggerAddEventConversationStateChanged - Triggering Conversation State —
string
<convstateindex> — EventConversationState
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tarcade.sc2map/MapScript.galaxy:3362
// Implementation
gv_highScore = lp_newHighScore;
ConversationDataStateSetValue("ArcadeGameVariables|HiScore", gv_highScore);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/thorner04.sc2map/MapScript.galaxy:2260
UnitKill(gv_secretDocuments);
libCamp_gf_DisplayCampaignMessage(PlayerGroupAll(), libCamp_ge_CampaignMessageType_Secret, StringExternal("Param/Value/DAF7934D"), libCamp_ge_CampaignMessageFormatNotFormat_FormatMessage);
ConversationDataStateSetValue("StoryState|HornerSecretMissionOn", 1);
return true;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6108
UnitGroupAdd(gv_hotspots_NoHighlightEffect, gf_ActorUnit(ge_ActorID_ActorYbarraMiscMerc));
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTychus, ge_RoomID_RoomCantina) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|TychusInCantina", 1);
}
else {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6111
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|TychusInCantina", 0);
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorHanson, ge_RoomID_RoomLab) == true)) {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6114
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorHanson, ge_RoomID_RoomLab) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|HansonInLab", 1);
}
else {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6117
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|HansonInLab", 0);
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTosh, ge_RoomID_RoomCantina) == true)) {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6120
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTosh, ge_RoomID_RoomCantina) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|ToshInCantina", 1);
}
else {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:6123
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|ToshInCantina", 0);
}
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10632
while (auto935A7AF7_i <= libCamp_gv_TSC_MISSION_LAST) {
lv_indexMission = libCamp_gv_tS_MapID[auto935A7AF7_i];
ConversationDataStateSetValue(libCamp_gf_MissionPitches(lv_indexMission), 0);
auto935A7AF7_i = auto935A7AF7_i + 1;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10635
auto935A7AF7_i = auto935A7AF7_i + 1;
}
ConversationDataStateSetValue(libCamp_gf_MissionPitches(gv_zPlanetPanel_Mission), 1);
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorZeratul), c_invalidPortraitId);
ConversationDataRun("Missionpitches", PlayerGroupAll(), c_conversationSkipNone, true);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12576
auto32677FE0_val = lp_scene;
if (auto32677FE0_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03A", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03B", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHorner", 0);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12577
if (auto32677FE0_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03A", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03B", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHorner", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyTosh03A", 0);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tarcade.sc2map — MapScript.galaxy:3362
// Implementation
gv_highScore = lp_newHighScore;
ConversationDataStateSetValue("ArcadeGameVariables|HiScore", gv_highScore);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/thorner04.sc2map — MapScript.galaxy:2260
UnitKill(gv_secretDocuments);
libCamp_gf_DisplayCampaignMessage(PlayerGroupAll(), libCamp_ge_CampaignMessageType_Secret, StringExternal("Param/Value/DAF7934D"), libCamp_ge_CampaignMessageFormatNotFormat_FormatMessage);
ConversationDataStateSetValue("StoryState|HornerSecretMissionOn", 1);
return true;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6108
UnitGroupAdd(gv_hotspots_NoHighlightEffect, gf_ActorUnit(ge_ActorID_ActorYbarraMiscMerc));
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTychus, ge_RoomID_RoomCantina) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|TychusInCantina", 1);
}
else {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6111
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|TychusInCantina", 0);
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorHanson, ge_RoomID_RoomLab) == true)) {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6114
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorHanson, ge_RoomID_RoomLab) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|HansonInLab", 1);
}
else {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6117
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|HansonInLab", 0);
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTosh, ge_RoomID_RoomCantina) == true)) {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6120
}
if ((gf_ActorIsEnabledInRoom(ge_ActorID_ActorTosh, ge_RoomID_RoomCantina) == true)) {
ConversationDataStateSetValue("CharacterLocationStatus|ToshInCantina", 1);
}
else {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:6123
}
else {
ConversationDataStateSetValue("CharacterLocationStatus|ToshInCantina", 0);
}
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10632
while (auto935A7AF7_i <= libCamp_gv_TSC_MISSION_LAST) {
lv_indexMission = libCamp_gv_tS_MapID[auto935A7AF7_i];
ConversationDataStateSetValue(libCamp_gf_MissionPitches(lv_indexMission), 0);
auto935A7AF7_i = auto935A7AF7_i + 1;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10635
auto935A7AF7_i = auto935A7AF7_i + 1;
}
ConversationDataStateSetValue(libCamp_gf_MissionPitches(gv_zPlanetPanel_Mission), 1);
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorZeratul), c_invalidPortraitId);
ConversationDataRun("Missionpitches", PlayerGroupAll(), c_conversationSkipNone, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12576
auto32677FE0_val = lp_scene;
if (auto32677FE0_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03A", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03B", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHorner", 0);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12577
if (auto32677FE0_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03A", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHanson03B", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyHorner", 0);
ConversationDataStateSetValue("SceneExtraObjects|Terran07TrophyTosh03A", 0);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:671
// Implementation
if ((libCamp_gf_NumberOfMissions(libCamp_ge_MissionCountOptions_Completed) == 9) && (ConversationDataStateGetValue("StoryTips|KeyboardShortcuts") == 0)) {
ConversationDataStateSetValue("StoryTips|KeyboardShortcuts", 1);
libCamp_gf_CreateTipFromConversationState("StoryTips|KeyboardShortcuts", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
Wait(libCamp_gv_campaignHintDelay, c_timeReal);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:751
if ((libCamp_gv_tS_UpgradeInfantry2 == true) && (ConversationDataStateGetValue("StoryTips|EngineeringBay2") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|EngineeringBay2", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|EngineeringBay2", 1);
Wait(libCamp_gv_campaignHintDelay, c_timeReal);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:757
if ((libCamp_gv_tS_UpgradeInfantry3 == true) && (ConversationDataStateGetValue("StoryTips|EngineeringBay3") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|EngineeringBay3", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|EngineeringBay3", 1);
Wait(libCamp_gv_campaignHintDelay, c_timeReal);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:763
if (((libCamp_gv_tS_UpgradeVehicle2 == true) || (libCamp_gv_tS_UpgradeShip2 == true)) && (ConversationDataStateGetValue("StoryTips|ArmoryLevel2") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|ArmoryLevel2", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|ArmoryLevel2", 1);
Wait(libCamp_gv_campaignHintDelay, c_timeReal);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:769
if (((libCamp_gv_tS_UpgradeVehicle3 == true) || (libCamp_gv_tS_UpgradeShip3 == true)) && (ConversationDataStateGetValue("StoryTips|ArmoryLevel3") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|ArmoryLevel3", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|ArmoryLevel3", 1);
Wait(libCamp_gv_campaignHintDelay, c_timeReal);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:779
// Implementation
HelpPanelAddTip(lp_players, libNtve_gf_FormatTipTitle(ConversationDataStateName(lp_convoState), lp_tipType), ConversationDataStateText(lp_convoState, "Description"), ConversationDataStateName(lp_convoState), ConversationDataStateImagePath(lp_convoState));
ConversationDataStateSetValue(lp_convoState, 1);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:3088
autoFDA5092A_val = lp_status;
if (autoFDA5092A_val == libCamp_ge_MissionStatus_Available) {
ConversationDataStateSetValue(ConversationDataStateIndex("MissionAvailable", (lp_mission)), lp_age);
}
else if (autoFDA5092A_val == libCamp_ge_MissionStatus_Completed) {
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:3091
}
else if (autoFDA5092A_val == libCamp_ge_MissionStatus_Completed) {
ConversationDataStateSetValue(ConversationDataStateIndex("MissionCompleted", (lp_mission)), lp_age);
}
else {
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:3340
lv_indexMission = libCamp_gv_tS_MapID[auto32A829D7_i];
if ((lv_indexMission == lp_mission)) {
ConversationDataStateSetValue(ConversationDataStateIndex("MissionLast", (lv_indexMission)), 1);
}
else {
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:3343
}
else {
ConversationDataStateSetValue(ConversationDataStateIndex("MissionLast", (lv_indexMission)), 0);
}
auto32A829D7_i = auto32A829D7_i + 1;
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:5352
auto42A6041C_ai = auto42A6041C_ai + 1;
}
ConversationDataStateSetValue("MissionsCompleted", libSwaC_gf_NumberOfMissions(libSwaC_ge_MissionCountOptions_Completed));
libSwaC_gf_ZS_UpdatePlanetData(libSwaC_gf_StoryMapPlanet(libSwaC_gf_CurrentMap()));
libSwaC_gf_ZS_UpdateKerriganType();
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:5982
}
ConversationDataStateSetValue("MissionsCompleted", libSwaC_gf_NumberOfMissions(libSwaC_ge_MissionCountOptions_Completed));
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:22045
libSwaC_gv_zS_DebugProgressLastTravel = null;
libSwaC_gf_ZS_UpdatePlanetData(libSwaC_gf_StoryMapPlanet(libSwaC_gv_zS_DebugProgressLastMission));
ConversationDataStateSetValue("MissionsCompleted", libSwaC_gf_NumberOfMissions(libSwaC_ge_MissionCountOptions_Completed));
libSwaC_gf_ZS_OpenCampaignBank();
libSwaC_gf_ZS_SaveMapToBank(null, libSwaC_gv_zS_CampaignBank, false);
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:399
}
if ((((libSwaC_gf_NumberOfMissionArcsCompleted() == 3) && (libSwaC_gf_MissionStatusCheck("ZChar3", libSwaC_ge_MissionStatus_Available) == true)) || ((libSwaC_gf_NumberOfMissionArcsCompleted() == 3) && (libSwaC_gf_MissionStatusCheck("ZExpedition3", libSwaC_ge_MissionStatus_Available) == true)) || ((libSwaC_gf_NumberOfMissionArcsCompleted() == 4) && (libSwaC_gf_MissionStatusCheck("ZZerus3", libSwaC_ge_MissionStatus_Completed) == true) && (libSwaC_gf_CurrentMap() == "ZStoryZerus")))) {
ConversationDataStateSetValue("TemporaryStoryStates|FirstDoWJustPlayed", 1);
}
else {
mods/warcoop/warcoopdata.sc2mod — base.sc2data/TriggerLibs/WarCoopData.galaxy:2429
libNtve_gf_SetAllSoundChannelVolumes(libNtve_ge_VolumeChannelMode_Speech, lp_listeningPlayers, 1.0);
ConversationDataStateSetValue(lp_conversationState, lp_conversationStateIndex);
ConversationDataRun(lp_conversation, lp_listeningPlayers, lv_skip, true);
ConversationDataStateSetValue(lp_conversationState, 0);
mods/warcoop/warcoopdata.sc2mod — base.sc2data/TriggerLibs/WarCoopData.galaxy:2431
ConversationDataStateSetValue(lp_conversationState, lp_conversationStateIndex);
ConversationDataRun(lp_conversation, lp_listeningPlayers, lv_skip, true);
ConversationDataStateSetValue(lp_conversationState, 0);
libNtve_gf_SetAllSoundChannelVolumes(libNtve_ge_VolumeChannelMode_Game, lp_listeningPlayers, 1.0);
}