# Set Planet Panel Contact Button State
Grammar — Set state as the current button state for playerGroup
Flags —Native
|Action
Sets the state of the contact button on the planet panel for the specified players.
# Arguments
playergroup
— PlayerGroupint
<preset::PlanetState3> — State
Returns — void
native void PlanetPanelSetContactButtonState(
playergroup players,
int inState,
);
# Related
Category: Story / Planet Panel / Planet Panel
- Planet Panel Planet Selected —
void
— TriggerAddEventPlanetMissionSelected - Planet Panel Launched —
void
— TriggerAddEventPlanetMissionLaunched - Planet Panel Canceled —
void
— TriggerAddEventPlanetPanelCanceled - Planet Panel Pressed Replay Button —
void
— TriggerAddEventPlanetPanelReplayPressed - Planet Panel Birth Complete —
void
— TriggerAddEventPlanetPanelBirthComplete - Planet Panel Death Complete —
void
— TriggerAddEventPlanetPanelDeathComplete - Clicked Planet —
int
<planet> — EventPlanetPanelMissionSelected - Selected Planet —
int
<planet> — PlanetGetSelected - Selected Mission Difficulty —
int
<difficulty> — EventPlanetPanelDifficultySelected - Planet Panel Contact Button State —
int
<preset::PlanetState3> — PlanetPanelGetContactButtonState - Set Planet Panel Contact Button State —
void
— PlanetPanelSetContactButtonState - Set Planet Panel Background Image —
void
— PlanetPanelSetBackgroundImage - Enable/Disable Planet Panel Close Button —
void
— PlanetPanelSetBackButtonEnabled - Set Planet Panel Close Button Text —
void
— PlanetPanelSetBackButtonText - Set Planet Panel Close Button Shortcut —
void
— PlanetPanelSetBackButtonShortcut - Set Planet Panel Close Button Tooltip —
void
— PlanetPanelSetBackButtonTooltip - Enable/Disable Planet Panel Dismiss Button —
void
— PlanetPanelSetDismissButtonEnabled - Set Selected Planet —
void
— PlanetSetSelected - Clear Selected Planet —
void
— PlanetClearSelected
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10238
gf_PlanetPanelAddPlanet(lp_planetID, true);
PlanetSetSelected(PlayerGroupAll(), PlanetLastCreated());
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
}
else {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10251
autoA6E46349_i = autoA6E46349_i + 1;
}
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateDisabled);
if ((gv_planetPanel_CurrentSelection != libCamp_ge_PlanetID_PlanetNone)) {
lv_planet = gf_PlanetPanelPlanetFromPlanetID(gv_planetPanel_CurrentSelection);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10257
PlanetSetSelected(PlayerGroupAll(), lv_planet);
if ((gf_PlanetPanelPlanetPitched(lv_planet) == true)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
}
else {
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10260
}
else {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateBlinking);
}
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:10281
gf_PauseNewItemInfo(false);
libCamp_gf_HideStoryUI(true, false);
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateDisabled);
gf_PlanetPanelDestory();
gf_StopAllTransmissionConversation();
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25070
}
if ((gf_PlanetPanelPlanetPitched(gf_PlanetPanelPlanetFromPlanetID(gv_planetPanel_CurrentSelection)) == true)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
return true;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25074
}
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateBlinking);
TriggerExecute(gt_PlanetPanelPlay, true, false);
return true;
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25174
if ((PlanetPanelGetContactButtonState(1) == c_planetPanelContactButtonStatePause)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
gf_StopAllTransmissionConversation();
return true;
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25196
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorValerian), PortraitGetPlanetPanel());
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorZeratul), PortraitGetPlanetPanel());
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePause);
gf_PlanetPanelGrayoutPortrait(false);
gv_planetPanel_PlanetPitched[(lv_planetID)] = true;
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:25206
if ((lv_planetID == gf_PlanetPanelPlanetIDFromPlanet(PlanetGetSelected(1)))) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
gf_PlanetPanelGrayoutPortrait(true);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10238
gf_PlanetPanelAddPlanet(lp_planetID, true);
PlanetSetSelected(PlayerGroupAll(), PlanetLastCreated());
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
}
else {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10251
autoA6E46349_i = autoA6E46349_i + 1;
}
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateDisabled);
if ((gv_planetPanel_CurrentSelection != libCamp_ge_PlanetID_PlanetNone)) {
lv_planet = gf_PlanetPanelPlanetFromPlanetID(gv_planetPanel_CurrentSelection);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10257
PlanetSetSelected(PlayerGroupAll(), lv_planet);
if ((gf_PlanetPanelPlanetPitched(lv_planet) == true)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
}
else {
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10260
}
else {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateBlinking);
}
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:10281
gf_PauseNewItemInfo(false);
libCamp_gf_HideStoryUI(true, false);
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateDisabled);
gf_PlanetPanelDestory();
gf_StopAllTransmissionConversation();
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:25070
}
if ((gf_PlanetPanelPlanetPitched(gf_PlanetPanelPlanetFromPlanetID(gv_planetPanel_CurrentSelection)) == true)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
return true;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:25074
}
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStateBlinking);
TriggerExecute(gt_PlanetPanelPlay, true, false);
return true;
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:25174
if ((PlanetPanelGetContactButtonState(1) == c_planetPanelContactButtonStatePause)) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
gf_StopAllTransmissionConversation();
return true;
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:25196
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorValerian), PortraitGetPlanetPanel());
ConversationDataRegisterPortrait(gf_ConvoCharacter(ge_ActorID_ActorZeratul), PortraitGetPlanetPanel());
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePause);
gf_PlanetPanelGrayoutPortrait(false);
gv_planetPanel_PlanetPitched[(lv_planetID)] = true;
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:25206
if ((lv_planetID == gf_PlanetPanelPlanetIDFromPlanet(PlanetGetSelected(1)))) {
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
gf_PlanetPanelGrayoutPortrait(true);
}
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignUILib.galaxy:7214
libVCUI_gv_pU_MissionPitchPlayed = true;
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePause);
libVCUI_gv_pU_PitchPlaying = true;
ConversationDataRun(libVoiC_gf_MissionPitch(libVCUI_gv_pU_MissionNextMap), PlayerGroupAll(), c_conversationSkipNone, true);
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignUILib.galaxy:7218
ConversationDataRun(libVoiC_gf_MissionPitch(libVCUI_gv_pU_MissionNextMap), PlayerGroupAll(), c_conversationSkipNone, true);
libVCUI_gv_pU_PitchPlaying = false;
PlanetPanelSetContactButtonState(PlayerGroupAll(), c_planetPanelContactButtonStatePlay);
return true;
}