# Actor From Portrait
Grammar — Actor for portrait
Flags —Native
|Function
Returns the actor for the specified portrait.
# Arguments
int
<portrait> — Portrait
Returns — actor
native actor ActorFromPortrait(int p);
# Related
Category: Actor / Utility
- Actor Get Text —
text
— ActorGetText - Actor From Reference —
actor
— ActorRefGet - Actor Scope Get Text —
text
— ActorScopeGetText - Actor From —
actor
— ActorFrom - Actor From Actor —
actor
— ActorFromActor - Actor From Doodad —
actor
— ActorFromDoodad - Actor From Portrait —
actor
— ActorFromPortrait - Actor From Dialog Item —
actor
— ActorFromDialogControl - Actor From Scope —
actor
— ActorFromScope - Actor From Unit —
actor
— libNtve_gf_MainActorofUnit - Actor Scope From —
actorscope
— ActorScopeFrom - Actor Scope From Actor —
actorscope
— ActorScopeFromActor - Actor Scope From Portrait —
actorscope
— ActorScopeFromPortrait - Actor Scope From Dialog Item —
actorscope
— ActorScopeFromDialogControl - Actor Scope From Unit —
actorscope
— ActorScopeFromUnit - Texture Slot Component —
int
— TextureGetSlotComponent - Texture Slot Name —
string
— TextureGetSlotName - Actor Set Reference —
void
— ActorRefSet - Apply Global Texture Group —
void
— ActorTextureGroupApplyGlobal - Remove Global Texture Group —
void
— ActorTextureGroupRemoveGlobal - Push Texture Group —
void
— ActorTextureGroupPush - Pop Texture Group —
void
— ActorTextureGroupPop - Make Actor Face Angle —
void
— libNtve_gf_MakeModelFaceAngle - Play Movie Texture On Unit Actor —
void
— libNtve_gf_PlayMovieTextureOnUnitActor - Stop All Video Textures On Unit —
void
— libNtve_gf_StopAllVideoTexturesOnUnit - Show/Hide Doodads In Region —
void
— libNtve_gf_ShowHideDoodadsInRegion - Actor Add Orient Update —
void
— ActorAddOrientUpdate
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13573
bool auto_gf_BriefingTZeratulVideoFadeIn_TriggerFunc (bool testConds, bool runActions) {
// Implementation
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimBracketStart Default Stand,Work,Start Stand,Work Stand,Work,End");
return true;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13589
bool auto_gf_BriefingTZeratulVideoFadeOut_TriggerFunc (bool testConds, bool runActions) {
// Implementation
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimBracketStop Default");
return true;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13596
// Implementation
if ((lp_transientAnim == true)) {
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimPlay BriefingVideoSwap Stand,Morph");
Wait(0.125, c_timeReal);
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13600
}
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "TextureVideoStopAll");
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), libNtve_gf_ActorMsg1("TextureSelectById", (lp_movie)));
gv_briefingVideoPlaying = lp_movie;
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:13601
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "TextureVideoStopAll");
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), libNtve_gf_ActorMsg1("TextureSelectById", (lp_movie)));
gv_briefingVideoPlaying = lp_movie;
}
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:29509
CameraApplyInfo(1, CameraInfoFromId(648), 2.0, -1, 10, true);
Wait(0.75, c_timeReal);
ActorSend(ActorFromPortrait(lv_portaitRight), "AnimPlay Briefing Talk PlayForever");
TransmissionSend(PlayerGroupAll(), TransmissionSourceFromModel(null), lv_portaitRight, "", SoundLink("THanson03ABriefingSwann00007", -1), null, null, 0.0, c_transmissionDurationAdd, true);
gf_BriefingPlayVideo("BriefingTHanson03a_02", lv__Room, ge_BriefingScreen_Center, true);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:29971
gf_ResetActorToLocation(ge_ActorID_ActorRaynor, PointFromId(680));
PortraitWaitForLoad(lv_portaitMiddlePlanet);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:29972
PortraitWaitForLoad(lv_portaitMiddlePlanet);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
CinematicFade(true, 0.5, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:31128
gf_ResetActorToLocation(ge_ActorID_ActorHorner, PointFromId(466));
CameraApplyInfo(1, CameraInfoFromId(467), 0.0, -1, 10, true);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:31129
CameraApplyInfo(1, CameraInfoFromId(467), 0.0, -1, 10, true);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
SoundtrackPlay(PlayerGroupAll(), c_soundtrackCategoryMusic, "TTosh03AMusicBriefing", c_soundtrackCueAny, c_soundtrackIndexAny, false);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13573
bool auto_gf_BriefingTZeratulVideoFadeIn_TriggerFunc (bool testConds, bool runActions) {
// Implementation
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimBracketStart Default Stand,Work,Start Stand,Work Stand,Work,End");
return true;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13589
bool auto_gf_BriefingTZeratulVideoFadeOut_TriggerFunc (bool testConds, bool runActions) {
// Implementation
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimBracketStop Default");
return true;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13596
// Implementation
if ((lp_transientAnim == true)) {
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "AnimPlay BriefingVideoSwap Stand,Morph");
Wait(0.125, c_timeReal);
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13600
}
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "TextureVideoStopAll");
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), libNtve_gf_ActorMsg1("TextureSelectById", (lp_movie)));
gv_briefingVideoPlaying = lp_movie;
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:13601
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), "TextureVideoStopAll");
ActorSend(ActorFromPortrait(gv_briefing_TZeratulPortraitZeratul), libNtve_gf_ActorMsg1("TextureSelectById", (lp_movie)));
gv_briefingVideoPlaying = lp_movie;
}
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:29509
CameraApplyInfo(1, CameraInfoFromId(648), 2.0, -1, 10, true);
Wait(0.75, c_timeReal);
ActorSend(ActorFromPortrait(lv_portaitRight), "AnimPlay Briefing Talk PlayForever");
TransmissionSend(PlayerGroupAll(), TransmissionSourceFromModel(null), lv_portaitRight, "", SoundLink("THanson03ABriefingSwann00007", -1), null, null, 0.0, c_transmissionDurationAdd, true);
gf_BriefingPlayVideo("BriefingTHanson03a_02", lv__Room, ge_BriefingScreen_Center, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:29971
gf_ResetActorToLocation(ge_ActorID_ActorRaynor, PointFromId(680));
PortraitWaitForLoad(lv_portaitMiddlePlanet);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:29972
PortraitWaitForLoad(lv_portaitMiddlePlanet);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
CinematicFade(true, 0.5, c_fadeStyleNormal, Color(0.00, 0.00, 0.00), 0.0, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:31128
gf_ResetActorToLocation(ge_ActorID_ActorHorner, PointFromId(466));
CameraApplyInfo(1, CameraInfoFromId(467), 0.0, -1, 10, true);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:31129
CameraApplyInfo(1, CameraInfoFromId(467), 0.0, -1, 10, true);
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimPlay Default Stand PlayForever");
ActorSend(ActorFromPortrait(lv_portaitMiddlePlanet), "AnimSetTimeScale Default 5.000000");
Wait(0.5, c_timeReal);
SoundtrackPlay(PlayerGroupAll(), c_soundtrackCategoryMusic, "TTosh03AMusicBriefing", c_soundtrackCueAny, c_soundtrackIndexAny, false);
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:1579
// Implementation
SoundPlay(SoundLink("UI_Evolutions_PlanetaryZoom", -1), PlayerGroupAll(), 100.0, 0.0);
ActorSend(ActorFromPortrait(libSwaC_gv_zS_PlanetPortrait), "AnimPlay Custom Spell PlayForever,NonLooping");
Wait(3.0, c_timeGame);
CameraSetValue(1, c_cameraValueDistance, CameraInfoGetValue(libSwaC_gv_zS_PlanetPortraitPlayerCamera, c_cameraValueDistance), 2.0, 100.0, 10.0);
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:3384
libNtve_gf_ClearPortraitAnimation(PortraitGetTriggerControl(libSwaC_gv_zS_SwarmHeroUIDialogLevelupPortrait[1]), "TriggerPortraitAnim");
DialogControlSetVisible(libSwaC_gv_zS_SwarmHeroUIDialogLevelupPortrait[1], PlayerGroupAll(), true);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_SwarmHeroUIDialogLevelupPortrait[1])), "AnimBlendTimeApply 0.000000");
libNtve_gf_PortraitSetAnim(PortraitGetTriggerControl(libSwaC_gv_zS_SwarmHeroUIDialogLevelupPortrait[1]), "Birth", "TriggerPortraitAnim", 0, 0.0);
Wait(2.0, c_timeGame);
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:8529
libNtve_gf_SetDialogItemModel(DialogControlLastCreated(), "SMX1_ArmyMutationConfirmationButtonEffect", PlayerGroupAll());
PortraitSetActor(PortraitGetTriggerControl(DialogControlLastCreated()), "PortraitActorWithDeath");
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(DialogControlLastCreated())), "SetVisibility");
}
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:8542
if ((libSwaC_gv_zS_ArmyCustomUpgradeCurrent == lv_indexUpgrade)) {
DialogControlSetVisible(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index], PlayerGroupAll(), true);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index])), "Signal Birth");
}
else {
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:8546
else {
DialogControlSetVisible(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index], PlayerGroupAll(), false);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index])), "Signal Death");
}
auto3A414717_ai = auto3A414717_ai + 1;
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:11605
libNtve_gf_SetDialogItemModel(DialogControlLastCreated(), "SMX1_KerriganAbilityConfirmationButtonEffect", PlayerGroupAll());
PortraitSetActor(PortraitGetTriggerControl(DialogControlLastCreated()), "PortraitActorWithDeath");
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(DialogControlLastCreated())), "SetVisibility");
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:11744
if ((libSwaC_gf_ZS_KerriganTierCost2(lv_tier) == true) && (libSwaC_gf_ZS_KerriganUITierIsAnimating(lv_tier) == false) && (libSwaC_gv_zSX_KerriganTechTiers[lv_tier] == lv_index)) {
DialogControlSetVisible(libSwaC_gv_zS_KerriganUITierButtons2[lv_tier][lv_index], PlayerGroupAll(), true);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_KerriganUITierButtons2[lv_tier][lv_index])), "SetVisibility 1");
}
else {
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:11748
else {
DialogControlSetVisible(libSwaC_gv_zS_KerriganUITierButtons2[lv_tier][lv_index], PlayerGroupAll(), false);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_KerriganUITierButtons2[lv_tier][lv_index])), "SetVisibility");
}
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:20456
if ((lv_upgradeSelected != libSwaC_gv_zS_ArmyCustomUpgradeCurrent)) {
if ((libSwaC_gv_zS_ArmyCustomUpgradeCurrent != null)) {
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[libSwaC_gf_ZS_ArmyCustomUpgradeUIIndex(libSwaC_gv_zS_ArmyCustomUpgradeCurrent)])), "Signal Death");
}
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:20460
DialogControlSetVisible(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index], PlayerGroupAll(), true);
ActorSend(ActorFromPortrait(PortraitGetTriggerControl(libSwaC_gv_zS_ArmyCustomUpgradeButtons2[lv_index])), "Signal Birth");
SoundPlay(SoundLink("UI_ArmyUpgrades_UpgradeSelect", -1), PlayerGroupAll(), 100.0, 0.0);
if ((libSwaC_gv_zS_ArmyCustomCategoryCurrent == "Zergling") && (libSwaC_gv_zS_ArmyCustomUpgradeSpamClickCount != -1)) {
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:2039
// Implementation
SoundPlay(SoundLink("UI_Evolutions_PlanetaryZoom", -1), PlayerGroupAll(), 100.0, 0.0);
ActorSend(ActorFromPortrait(libVCMI_gv_pM_PlanetPortrait), "AnimPlay Custom Spell PlayForever,NonLooping");
Wait(3.0, c_timeGame);
CameraSetValue(1, c_cameraValueDistance, CameraInfoGetValue(libVCMI_gv_pM_PlanetPortraitPlayerCamera, c_cameraValueDistance), 2.0, 100.0, 10.0);
campaigns/voidstory.sc2campaign — base.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:2059
// Implementation
PortraitSetOffscreen(libVCMI_gv_pM_PlanetPortrait, true);
ActorSend(ActorFromPortrait(libVCMI_gv_pM_PlanetPortrait), "AnimClear Custom 0.000000");
return true;
}
mods/core.sc2mod — base.sc2data/TriggerLibs/NativeLib.galaxy:4159
// Automatic Variable Declarations
// Implementation
libNtve_gf_PlayAnimation(ActorFromPortrait(lp_Portrait), lp_identifier, lp_Anim, lp_flags, lp_blendTime);
}
mods/core.sc2mod — base.sc2data/TriggerLibs/NativeLib.galaxy:4165
// Automatic Variable Declarations
// Implementation
libNtve_gf_ClearAnimation(ActorFromPortrait(lp_portrait), lp_identifier);
}
mods/core.stormmod — base.stormdata/TriggerLibs/NativeLib.galaxy:3458
// Automatic Variable Declarations
// Implementation
libNtve_gf_PlayAnimation(ActorFromPortrait(lp_Portrait), lp_identifier, lp_Anim, lp_flags, lp_blendTime);
}
mods/core.stormmod — base.stormdata/TriggerLibs/NativeLib.galaxy:3464
// Automatic Variable Declarations
// Implementation
libNtve_gf_ClearAnimation(ActorFromPortrait(lp_portrait), lp_identifier);
}
mods/missionpacks/novacampaign.sc2mod — base.sc2data/LibNCMI.galaxy:2718
// Implementation
SoundPlay(SoundLink("UI_Evolutions_PlanetaryZoom", -1), PlayerGroupAll(), 100.0, 0.0);
ActorSend(ActorFromPortrait(libNCMI_gv_NM_PlanetPortrait), "AnimPlay Custom Spell PlayForever,NonLooping");
Wait(3.0, c_timeGame);
CameraSetValue(1, c_cameraValueDistance, CameraInfoGetValue(libNCMI_gv_NM_PlanetPortraitPlayerCamera, c_cameraValueDistance), 2.0, 100.0, 10.0);
mods/missionpacks/novacampaign.sc2mod — base.sc2data/LibNCMI.galaxy:2737
// Implementation
PortraitSetOffscreen(libNCMI_gv_NM_PlanetPortrait, true);
ActorSend(ActorFromPortrait(libNCMI_gv_NM_PlanetPortrait), "AnimClear Custom 0.000000");
return true;
}
mods/voidprologue.sc2mod — base.sc2data/LibA3DDD02B.galaxy:1265
// Implementation
SoundPlay(SoundLink("UI_Evolutions_PlanetaryZoom", -1), PlayerGroupAll(), 100.0, 0.0);
ActorSend(ActorFromPortrait(libA3DDD02B_gv_pP_PlanetPortrait), "AnimPlay Custom Spell PlayForever,NonLooping");
Wait(3.0, c_timeGame);
CameraSetValue(1, c_cameraValueDistance, CameraInfoGetValue(libA3DDD02B_gv_pP_PlanetPortraitPlayerCamera, c_cameraValueDistance), 2.0, 100.0, 10.0);
mods/voidprologue.sc2mod — base.sc2data/LibA3DDD02B.galaxy:1291
SoundChannelMute(PlayerGroupAll(), c_soundCategoryDoodad, false);
PortraitSetOffscreen(libA3DDD02B_gv_pP_PlanetPortrait, true);
ActorSend(ActorFromPortrait(libA3DDD02B_gv_pP_PlanetPortrait), "AnimClear Custom 0.000000");
if ((libA3DDD02B_gv_pP_PlanetPortraitEvoMissionLight != null)) {
GameSetLighting(libA3DDD02B_gv_pP_PlanetPortraitEvoMissionLight, 0.0);