# Data Conversation State
Grammar — Conversation stateIndex|State
Flags —Native
|Function
Converts a conversation state index to an integer.
# Arguments
string
<convstateindex> — State Index
Returns — int
native int ConversationDataStateGetValue(
string stateIndex,
);
# Related
Category: Conversation / Data Conversation Tools
- Mark Data Conversation Choice As Read/Unread —
void
— ConversationDataChoiceSetState - Mark Data Conversation Choice As Picked/Unpicked —
void
— ConversationDataChoiceSetPicked - Set Data Conversation Choice Picked Count —
void
— ConversationDataChoiceSetPickedCount - Set Data Conversation Line Picked Count —
void
— ConversationDataLineSetPickedCount - Set Data Conversation Line Players —
void
— ConversationDataLineSetPlayers - Reset Data Conversation Line Players —
void
— ConversationDataLineResetPlayers - Show/Hide Data Conversation Line For Observers —
void
— ConversationDataLineHideForObservers - Set Data Conversation Listener Gender —
void
— ConversationDataSetListenerGender - Save Data Conversation State Value —
void
— ConversationDataSaveStateValue - Load Data Conversation State Value —
void
— ConversationDataLoadStateValue - Save Data Conversation State Values —
void
— ConversationDataSaveStateValues - Load Data Conversation State Values —
void
— ConversationDataLoadStateValues - Reset Data Conversation State Values —
void
— ConversationDataResetStateValues - Save Data Conversation Lines And Choices —
void
— ConversationDataSaveNodeState - Load Data Conversation Lines And Choices —
void
— ConversationDataLoadNodeState - Reset Data Conversation Lines And Choices —
void
— ConversationDataResetNodeState - Preload Data Conversation Lines —
void
— ConversationDataPreloadLines - Preload Data Conversation Lines For Next Map —
void
— ConversationDataPreloadLinesQueue - Simulate Data Conversation —
void
— ConversationDataSimulateRun - Data Conversation State —
int
— ConversationDataStateGetValue - Data Conversation State Count —
int
— ConversationDataStateIndexCount - Data Conversation State Name —
text
— ConversationDataStateName - Data Conversation State Custom Value —
fixed
— ConversationDataStateFixedValue - Data Conversation State Image —
string
<filepath> — ConversationDataStateImagePath - Data Conversation State Movie —
string
<filepath> — ConversationDataStateMoviePath - Data Conversation State Model —
string
<gamelink::Model> — ConversationDataStateModel - Data Conversation State Text —
text
— ConversationDataStateText - Data Conversation State Text Tag Edge —
int
<preset::TextTagEdge> — ConversationDataStateImageEdge - Data Conversation State Upgrade —
string
<gamelink::Upgrade> — ConversationDataStateUpgrade - Data Conversation State Ability Command —
abilcmd
— ConversationDataStateAbilCmd - Data Conversation State Attachment Point —
string
<preset::AttachPoints> — ConversationDataStateAttachPoint - Data Conversation Can Be Run —
bool
— ConversationDataCanRun - Data Conversation Choice Count —
int
— ConversationDataChoiceCount - Data Conversation Choice Name —
string
— ConversationDataChoiceId - Data Conversation Choice Picked —
bool
<preset::PickedState> — ConversationDataChoiceGetPicked - Data Conversation Choice Picked Count —
int
— ConversationDataChoiceGetPickedCount - Data Conversation Choice State —
int
<preset::ReplyState> — ConversationDataChoiceGetState - Data Conversation Line Count —
int
— ConversationDataLineCount - Data Conversation Line Name —
string
— ConversationDataLineId - Data Conversation Line Picked Count —
int
— ConversationDataLineGetPickedCount - Data Conversation Lines With Tag
- Data Conversation Sound —
string
<gamelink::Sound> — ConversationDataGetSound - Data Conversation Speaker —
string
<gamelink::Character> — ConversationDataGetSpeaker - Active Data Conversation Camera —
string
<convstateindex> — ConversationDataActiveCamera - Active Data Conversation Line —
string
<convline> — ConversationDataActiveLine - Active Data Conversation Sound —
string
<gamelink::Sound> — ConversationDataActiveSound - Last Data Conversation Was Skipped —
bool
— ConversationDataWasSkipped
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tarcade.sc2map/MapScript.galaxy:4083
VisRevealArea(gv_p1_USER, RegionEntireMap(), 0.0, false);
VisRevealArea(gv_p2_ENEMY, RegionEntireMap(), 0.0, false);
gv_highScore = ConversationDataStateGetValue("ArcadeGameVariables|HiScore");
gf_InitCamera();
gf_PrepareBorder();
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:9523
void gf_AddFlashingTextTagToHotspot (unit lp_unit, string lp_conversationStateIndex, int lp_offsetX, int lp_offsetY, int lp_edgeOffsetX, int lp_edgeOffsetY) {
// Implementation
if ((ConversationDataStateGetValue(lp_conversationStateIndex) == 1)) {
return ;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10573
gf_ZPlanetPanelSetPitchButtonState(c_planetPanelContactButtonStatePlay);
CinematicFade(true, 0.0, c_fadeStyleNormal, ColorWithAlpha(0.00, 0.00, 0.00, 0.00), 0.0, false);
if ((ConversationDataStateGetValue(libCamp_gf_MissionPitches(gv_zPlanetPanel_Mission)) == 0)) {
gf_ZPlanetPanelPitch();
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10752
libCamp_gf_AddRoomChangePanelButton(StringExternal("Param/Value/B0EC18CF"), gt_CharRoomUIButtonResponse, gt_CharRoomUIButtonUpdate, (ge_CharRoomUI_CharRoomUIMercenaries), StringToText(""));
libCamp_gf_AddRoomChangePanelButton(StringExternal("Param/Value/40C21185"), gt_CharRoomUIButtonResponse, gt_CharRoomUIButtonUpdate, (ge_CharRoomUI_CharRoomUINews), StringToText(""));
if ((ConversationDataStateGetValue("Hotspots|CantinaTV") == 0)) {
libCamp_gf_FlashRoomChangePanelButton(libCamp_gf_LastAddRoomChangePanelButton());
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12693
autoD33241BE_val = lp_scene;
if (autoD33241BE_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHanson03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonA);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12697
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHanson03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonB);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12701
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyTosh03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyToshA);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12705
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyTosh03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyToshB);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12709
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHorner") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHorner);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12715
}
else if (autoD33241BE_val == libCamp_ge_SceneID_SceneTerran10RaynorsDream) {
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran10TrophyHanson03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonA);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:12719
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran10TrophyHanson03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonB);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tarcade.sc2map — MapScript.galaxy:4083
VisRevealArea(gv_p1_USER, RegionEntireMap(), 0.0, false);
VisRevealArea(gv_p2_ENEMY, RegionEntireMap(), 0.0, false);
gv_highScore = ConversationDataStateGetValue("ArcadeGameVariables|HiScore");
gf_InitCamera();
gf_PrepareBorder();
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:9523
void gf_AddFlashingTextTagToHotspot (unit lp_unit, string lp_conversationStateIndex, int lp_offsetX, int lp_offsetY, int lp_edgeOffsetX, int lp_edgeOffsetY) {
// Implementation
if ((ConversationDataStateGetValue(lp_conversationStateIndex) == 1)) {
return ;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10573
gf_ZPlanetPanelSetPitchButtonState(c_planetPanelContactButtonStatePlay);
CinematicFade(true, 0.0, c_fadeStyleNormal, ColorWithAlpha(0.00, 0.00, 0.00, 0.00), 0.0, false);
if ((ConversationDataStateGetValue(libCamp_gf_MissionPitches(gv_zPlanetPanel_Mission)) == 0)) {
gf_ZPlanetPanelPitch();
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10752
libCamp_gf_AddRoomChangePanelButton(StringExternal("Param/Value/B0EC18CF"), gt_CharRoomUIButtonResponse, gt_CharRoomUIButtonUpdate, (ge_CharRoomUI_CharRoomUIMercenaries), StringToText(""));
libCamp_gf_AddRoomChangePanelButton(StringExternal("Param/Value/40C21185"), gt_CharRoomUIButtonResponse, gt_CharRoomUIButtonUpdate, (ge_CharRoomUI_CharRoomUINews), StringToText(""));
if ((ConversationDataStateGetValue("Hotspots|CantinaTV") == 0)) {
libCamp_gf_FlashRoomChangePanelButton(libCamp_gf_LastAddRoomChangePanelButton());
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12693
autoD33241BE_val = lp_scene;
if (autoD33241BE_val == libCamp_ge_SceneID_SceneTerran07BarFight) {
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHanson03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonA);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12697
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHanson03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonB);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12701
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyTosh03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyToshA);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12705
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyTosh03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyToshB);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12709
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran07TrophyHorner") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHorner);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12715
}
else if (autoD33241BE_val == libCamp_ge_SceneID_SceneTerran10RaynorsDream) {
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran10TrophyHanson03A") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonA);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:12719
}
if ((ConversationDataStateGetValue("SceneExtraObjects|Terran10TrophyHanson03B") > 0)) {
UnitGroupAdd(lv_group, gv_cantinaTrophyHansonB);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:670
// 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());
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:749
}
if ((libCamp_gv_tS_UpgradeInfantry2 == true) && (ConversationDataStateGetValue("StoryTips|EngineeringBay2") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|EngineeringBay2", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|EngineeringBay2", 1);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:755
}
if ((libCamp_gv_tS_UpgradeInfantry3 == true) && (ConversationDataStateGetValue("StoryTips|EngineeringBay3") == 0)) {
libCamp_gf_CreateTipFromConversationState("StoryTips|EngineeringBay3", libNtve_ge_TipType_NormalTip, PlayerGroupAll());
ConversationDataStateSetValue("StoryTips|EngineeringBay3", 1);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:761
}
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);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:767
}
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);
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:2659
while (auto06336F42_i <= libCamp_gv_TSC_MISSION_LAST) {
lv_mission = libCamp_gv_tS_MapID[auto06336F42_i];
if ((ConversationDataStateGetValue(ConversationDataStateIndex("MissionLast", (lv_mission))) == 1)) {
return lv_mission;
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:2741
auto87D2C2FD_val = lp_status;
if (auto87D2C2FD_val == libCamp_ge_MissionStatus_Available) {
return ConversationDataStateGetValue(ConversationDataStateIndex("MissionAvailable", (lp_mission)));
}
else if (auto87D2C2FD_val == libCamp_ge_MissionStatus_Completed) {
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:2744
}
else if (auto87D2C2FD_val == libCamp_ge_MissionStatus_Completed) {
return ConversationDataStateGetValue(ConversationDataStateIndex("MissionCompleted", (lp_mission)));
}
else {
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:4470
// Automatic Variable Declarations
// Implementation
return ConversationDataStateGetValue(libCamp_gv_tS_MissionObjConvoID[(lp_objective)]);
}
campaigns/libertystory.sc2campaign — base.sc2data/TriggerLibs/CampaignLib.galaxy:6019
// Automatic Variable Declarations
// Implementation
return ConversationDataStateGetValue(libCamp_gv_tS_StoryStateConvoID[(lp_stateID)]);
}
campaigns/swarm.sc2campaign — base.sc2maps/maps/campaign/swarm/zstoryzerus.sc2map/MapScript.galaxy:449
SoundtrackPlay(PlayerGroupAll(), c_soundtrackCategoryMusic, "zSM_Zeratul", c_soundtrackCueAny, c_soundtrackIndexAny, false);
lib281DEC45_gf_PlayScriptedConversation("zSM_Zeratul", c_conversationSkipSimple, lib281DEC45_ge_SwarmStoryFadeStyle_FadeOutOnSkip | lib281DEC45_ge_SwarmStoryFadeStyle_FadeInAfter, null);
if ((ConversationDataStateGetValue("GrantStoryAchievement|Judgment Day") == 1)) {
lib281DEC45_gf_SetCharacterNew("Hotspot - Zerus - Void Seeker", false);
libSwaC_gf_CampaignAwardAchievement("ZeratulDestination", 1);
campaigns/swarm.sc2campaign/base.sc2maps/maps/campaign/swarm/zstoryzerus.sc2map — MapScript.galaxy:449
SoundtrackPlay(PlayerGroupAll(), c_soundtrackCategoryMusic, "zSM_Zeratul", c_soundtrackCueAny, c_soundtrackIndexAny, false);
lib281DEC45_gf_PlayScriptedConversation("zSM_Zeratul", c_conversationSkipSimple, lib281DEC45_ge_SwarmStoryFadeStyle_FadeOutOnSkip | lib281DEC45_ge_SwarmStoryFadeStyle_FadeInAfter, null);
if ((ConversationDataStateGetValue("GrantStoryAchievement|Judgment Day") == 1)) {
lib281DEC45_gf_SetCharacterNew("Hotspot - Zerus - Void Seeker", false);
libSwaC_gf_CampaignAwardAchievement("ZeratulDestination", 1);
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3977
autoA9CD1361_val = lp_character;
if (autoA9CD1361_val == "Zagara") {
if ((ConversationDataStateGetValue("GrantStoryAchievement|Visionary") == 1)) {
libSwaC_gf_CampaignAwardAchievement("KerriganTeachesZagara", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3980
libSwaC_gf_CampaignAwardAchievement("KerriganTeachesZagara", 1);
}
else if ((ConversationDataStateGetValue("GrantStoryAchievement|RallyTroopsZagara") == 1)) {
AchievementTermQuantitySet(1, "ZStory_Rally_Zagara", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3985
}
else if (autoA9CD1361_val == "Evolution Master") {
if ((ConversationDataStateGetValue("GrantStoryAchievement|FashionStatementEvo") == 1)) {
AchievementTermQuantitySet(1, "ZStoryConversation_Abathur_NewLook", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3988
AchievementTermQuantitySet(1, "ZStoryConversation_Abathur_NewLook", 1);
}
else if ((ConversationDataStateGetValue("GrantStoryAchievement|RallyTroopsAbathur") == 1)) {
AchievementTermQuantitySet(1, "ZStory_Rally_Abathur", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3993
}
else if (autoA9CD1361_val == "Zerg Adjutant") {
if ((ConversationDataStateGetValue("GrantStoryAchievement|FashionStatementIzsha") == 1)) {
AchievementTermQuantitySet(1, "ZStoryConversation_Izsha_NewLook", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:3996
AchievementTermQuantitySet(1, "ZStoryConversation_Izsha_NewLook", 1);
}
else if ((ConversationDataStateGetValue("GrantStoryAchievement|RallyTroopsIzsha") == 1)) {
AchievementTermQuantitySet(1, "ZStory_Rally_Izsha", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:4002
else if (autoA9CD1361_val == "Primal Ancient") {
AchievementTermQuantitySet(1, "ZStoryConversation_AncientOne", 1);
if ((ConversationDataStateGetValue("GrantStoryAchievement|FashionStatementZurvan") == 1)) {
AchievementTermQuantitySet(1, "ZStoryConversation_Zurvan_NewLook", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:4007
}
else if (autoA9CD1361_val == "Stukov") {
if ((ConversationDataStateGetValue("GrantStoryAchievement|Xelnaga Secrets") == 1)) {
libSwaC_gf_CampaignAwardAchievement("SkygeirrLearnXelnagaPurpose", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:4010
libSwaC_gf_CampaignAwardAchievement("SkygeirrLearnXelnagaPurpose", 1);
}
else if ((ConversationDataStateGetValue("GrantStoryAchievement|RallyTroopsStukov") == 1)) {
AchievementTermQuantitySet(1, "ZStory_Rally_Stukov", 1);
}
campaigns/swarmstoryutil.sc2mod — base.sc2data/Lib281DEC45.galaxy:4015
}
else if (autoA9CD1361_val == "Primal Advisor") {
if ((ConversationDataStateGetValue("GrantStoryAchievement|RallyTroopsDehaka") == 1)) {
AchievementTermQuantitySet(1, "ZStory_Rally_Dehaka", 1);
}