# Attach Actor To Unit

Grammar — Attach actor to attachPoint|Attach Point on unit
FlagsAction

Creates an actor attached to a unit at the specified attach point. Use “Last Created Actor” to get the actor.

# Arguments

  • unit — Unit
  • string [ gamelink::Actor ] — Actor
  • string [ preset::AttachPoints ] — AttachPoint

Returns — actor

actor libNtve_gf_AttachActorToUnit(
	unit lp_unit,
	string lp_actor,
	string lp_attachPoint,
);

Category: Actor / Create Actors

# Examples

# campaigns/liberty.sc2campaign

MapScript.galaxy

// L1802
libNtve_gf_AttachActorToUnit(gv_boss, "SS_TerraTronMissileLaunch", lp_launchAttachPoint)
// L785
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L971
libNtve_gf_AttachActorToUnit(gv_crazyOldClarice, "TalkIcon", "Ref_Origin")
// L1140
libNtve_gf_AttachActorToUnit(UnitFromId(59), "TalkIcon", "Ref_Origin")
// L1303
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1354
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1400
libNtve_gf_AttachActorToUnit(gv_mutteringJohn, "TalkIcon", "Ref_Origin")
// L1483
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1764
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1907
libNtve_gf_AttachActorToUnit(lv_speaker, "TalkIcon", "Ref_Origin")
// L2080
libNtve_gf_AttachActorToUnit(gv_southieSpeaker, "TalkIcon", "Ref_Origin")
// L1923
libNtve_gf_AttachActorToUnit(auto1789B74F_var, "XelNagaShieldDomeImpact", "Ref_Center")
// L1802
libNtve_gf_AttachActorToUnit(gv_boss, "SS_TerraTronMissileLaunch", lp_launchAttachPoint)
// L785
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L971
libNtve_gf_AttachActorToUnit(gv_crazyOldClarice, "TalkIcon", "Ref_Origin")
// L1140
libNtve_gf_AttachActorToUnit(UnitFromId(59), "TalkIcon", "Ref_Origin")
// L1303
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1354
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1400
libNtve_gf_AttachActorToUnit(gv_mutteringJohn, "TalkIcon", "Ref_Origin")
// L1483
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1764
libNtve_gf_AttachActorToUnit(gv_raynor, "TalkIcon", "Ref_Origin")
// L1907
libNtve_gf_AttachActorToUnit(lv_speaker, "TalkIcon", "Ref_Origin")
// L2080
libNtve_gf_AttachActorToUnit(gv_southieSpeaker, "TalkIcon", "Ref_Origin")
// L1923
libNtve_gf_AttachActorToUnit(auto1789B74F_var, "XelNagaShieldDomeImpact", "Ref_Center")
// L1463
libNtve_gf_AttachActorToUnit(UnitFromId(52), "ZergCavesLoopSound", "Ref_Center")
// L1465
libNtve_gf_AttachActorToUnit(UnitFromId(146), "ZergCavesLoopSound", "Ref_Center")
// L1467
libNtve_gf_AttachActorToUnit(UnitFromId(781), "ZergCavesLoopSound", "Ref_Center")
// L1155
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator4", "Ref_Origin")
// L1160
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator8", "Ref_Origin")
// L1165
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator12", "Ref_Origin")
// L1169
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator16", "Ref_Origin")
// L3505
libNtve_gf_AttachActorToUnit(gv_carrionDecayEmitter, "EvoSwarmHostDecayLoopSound", "Center")
// L3605
libNtve_gf_AttachActorToUnit(gv_carrionDecayEmitter, "EvoSwarmHostDecayLoopSound", "Center")
// L3505
libNtve_gf_AttachActorToUnit(gv_carrionDecayEmitter, "EvoSwarmHostDecayLoopSound", "Center")
// L3605
libNtve_gf_AttachActorToUnit(gv_carrionDecayEmitter, "EvoSwarmHostDecayLoopSound", "Center")
// L1463
libNtve_gf_AttachActorToUnit(UnitFromId(52), "ZergCavesLoopSound", "Ref_Center")
// L1465
libNtve_gf_AttachActorToUnit(UnitFromId(146), "ZergCavesLoopSound", "Ref_Center")
// L1467
libNtve_gf_AttachActorToUnit(UnitFromId(781), "ZergCavesLoopSound", "Ref_Center")
// L1155
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator4", "Ref_Origin")
// L1160
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator8", "Ref_Origin")
// L1165
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator12", "Ref_Origin")
// L1169
libNtve_gf_AttachActorToUnit(gv_kraith, "KraithCrashingChargeIndicator16", "Ref_Origin")

# campaigns/swarmstory.sc2campaign

SwarmCampaignLib.galaxy

// L11855
libNtve_gf_AttachActorToUnit(libSwaC_gv_zS_KerriganUIBackground, lv_actor, "Ref_Target")
// L21594
libNtve_gf_AttachActorToUnit(libSwaC_gv_zS_KerriganUIBackground, "KerriganAbilityUISurge", "Ref_Target 01")

# mods/heroesdata.stormmod

GameDataHelperLib.galaxy

// L14809
libNtve_gf_AttachActorToUnit(lv_boat, "GenericHeroLight", "Ref_Origin")

# mods/heroesmapmods/battlegroundmapmods/hauntedmines.stormmod

LibMHtM.galaxy

// L308
libNtve_gf_AttachActorToUnit(lp_heroUnit, "HeroLightLowIntensity", "Ref_Origin")
// L311
libNtve_gf_AttachActorToUnit(lp_heroUnit, "UndergroundHeroLight", "Ref_Origin")

# mods/heroesmapmods/battlegroundmapmods/tombofthespiderqueen.stormmod

LibMSOC.galaxy

// L646
libNtve_gf_AttachActorToUnit(lp_heroUnit, "TombCameraLight", "Ref_Origin")