# Play Portrait Animation
Grammar — Set Portrait animation to Anim as identifier, using flags|Options options and blendTime blend time
Flags —Action
Tells a portrait to play an animation.
# Arguments
int
<portrait> — Portraitstring
<modelanim> — Animationstring
— Identifierint
<preset::AnimationFlag> — Flagsfixed
— Blend Time
Returns — void
void libNtve_gf_PortraitSetAnim(
int lp_Portrait,
string lp_Anim,
string lp_identifier,
int lp_flags,
fixed lp_blendTime,
);
# Related
Category: Portrait / Advanced
- Destroy All Portraits —
void
— PortraitDestroyAll - Destroy Portrait —
void
— PortraitDestroy - Play Portrait Animation —
void
— libNtve_gf_PortraitSetAnim - Set Portrait Camera —
void
— PortraitSetCamera - Set Portrait Border Texture —
void
— PortraitSetBorderTexture - Set Portrait Light —
void
— PortraitSetLight - Set Portrait Model —
void
— PortraitSetModel - Set Portrait Model And Play Animation —
void
— PortraitSetModelAnim - Set Portrait Position —
void
— PortraitSetPosition - Set Portrait Size —
void
— PortraitSetSize - Set Portrait Transition Model —
void
— PortraitSetTransitionModel - Set Portrait Mouse Target —
void
— PortraitSetMouseTarget - Set Portrait Channel —
void
— PortraitSetChannel - Set Portrait Render Type —
void
— PortraitSetRenderType - Mute/Unmute Portrait —
void
— PortraitSetMuted - Pause/Unpause Portrait —
void
— PortraitSetPaused - Set Portrait Tint Color —
void
— PortraitSetTintColor - Set Portrait Team Color —
void
— PortraitSetTeamColor - Set Portrait Actor —
void
— PortraitSetActor - Turn Portrait Border On/Off —
void
— PortraitSetBorderVisible - Turn Portrait Background On/Off —
void
— PortraitSetBackgroundVisible - Turn Portrait Fullscreen On/Off —
void
— PortraitSetFullscreen - Turn Portrait Offscreen On/Off —
void
— PortraitSetOffscreen - Turn Portrait Transition On/Off —
void
— PortraitUseTransition - Force Portrait Transition On/Off —
void
— PortraitForceTransition - Clear Portrait Animation —
void
— libNtve_gf_ClearPortraitAnimation - Wait For Portrait To Load —
void
— PortraitWaitForLoad
# Examples
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:15165
}
SoundPlay(SoundLink("TUINewRoomActorOnline", 0), PlayerGroupAll(), 100.0, 0.0);
libNtve_gf_PortraitSetAnim(gv_newItems[lv_newItemIndex].lv_flash, "Birth", "TriggerPortraitAnim", c_animFlagFullMatch | c_animFlagPlayForever | c_animFlagNonLooping, 0.0);
if ((gv_newItemInfoPaused == true)) {
DialogSetVisible(DialogLastCreated(), PlayerGroupAll(), false);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tstory01.sc2map/MapScript.galaxy:15277
lv_interval = (1.5 / IntToFixed(lv_fadeTimes));
lv_transparencyChange = (100.0 / IntToFixed(lv_fadeTimes));
libNtve_gf_PortraitSetAnim(gv_newItems[lv_newItemIndex].lv_flash, "Death", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
autoBB9F0C83_ae = lv_fadeTimes;
autoBB9F0C83_ai = 1;
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tzeratul02.sc2map/MapScript.galaxy:7135
PortraitSetFullscreen(PortraitLastCreated(), true);
PortraitSetLight(PortraitLastCreated(), "VC_Zeratul2_Planet");
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand A", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
PortraitSetBorderVisible(PortraitLastCreated(), false);
Wait(1.0, c_timeGame);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tzeratul02.sc2map/MapScript.galaxy:7142
// Transmission - SoundLink("TZeratul02Preserver200040", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200040", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand B", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver300041", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver300041", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tzeratul02.sc2map/MapScript.galaxy:7147
// Transmission - SoundLink("TZeratul02Preserver100042", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver100042", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand C", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver200043", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200043", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/liberty.sc2campaign — base.sc2maps/maps/campaign/tzeratul02.sc2map/MapScript.galaxy:7150
// Transmission - SoundLink("TZeratul02Preserver200043", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200043", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand D", "TriggerPortraitAnim", c_animFlagPlayForever | c_animFlagNonLooping, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver300062", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver300062", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:15165
}
SoundPlay(SoundLink("TUINewRoomActorOnline", 0), PlayerGroupAll(), 100.0, 0.0);
libNtve_gf_PortraitSetAnim(gv_newItems[lv_newItemIndex].lv_flash, "Birth", "TriggerPortraitAnim", c_animFlagFullMatch | c_animFlagPlayForever | c_animFlagNonLooping, 0.0);
if ((gv_newItemInfoPaused == true)) {
DialogSetVisible(DialogLastCreated(), PlayerGroupAll(), false);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tstory01.sc2map — MapScript.galaxy:15277
lv_interval = (1.5 / IntToFixed(lv_fadeTimes));
lv_transparencyChange = (100.0 / IntToFixed(lv_fadeTimes));
libNtve_gf_PortraitSetAnim(gv_newItems[lv_newItemIndex].lv_flash, "Death", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
autoBB9F0C83_ae = lv_fadeTimes;
autoBB9F0C83_ai = 1;
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tzeratul02.sc2map — MapScript.galaxy:7135
PortraitSetFullscreen(PortraitLastCreated(), true);
PortraitSetLight(PortraitLastCreated(), "VC_Zeratul2_Planet");
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand A", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
PortraitSetBorderVisible(PortraitLastCreated(), false);
Wait(1.0, c_timeGame);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tzeratul02.sc2map — MapScript.galaxy:7142
// Transmission - SoundLink("TZeratul02Preserver200040", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200040", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand B", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver300041", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver300041", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tzeratul02.sc2map — MapScript.galaxy:7147
// Transmission - SoundLink("TZeratul02Preserver100042", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver100042", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand C", "TriggerPortraitAnim", c_animFlagPlayForever, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver200043", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200043", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/liberty.sc2campaign/base.sc2maps/maps/campaign/tzeratul02.sc2map — MapScript.galaxy:7150
// Transmission - SoundLink("TZeratul02Preserver200043", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver200043", 0), c_transmissionDurationAdd, 0.0, true);
libNtve_gf_PortraitSetAnim(PortraitLastCreated(), "Stand D", "TriggerPortraitAnim", c_animFlagPlayForever | c_animFlagNonLooping, c_animTimeDefault);
// Transmission - SoundLink("TZeratul02Preserver300062", 0)
libCamp_gf_SendTransmissionCampaign(null, SoundLink("TZeratul02Preserver300062", 0), c_transmissionDurationAdd, 0.0, true);
campaigns/swarmstory.sc2campaign — base.sc2data/TriggerLibs/SwarmCampaignLib.galaxy:3385
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);
DialogControlSetVisible(libSwaC_gv_zS_SwarmHeroUIDialogLevelupPortrait[1], PlayerGroupAll(), false);