# Unit Can Create Effect On Unit

Grammarcaster can create effect on target
FlagsFunction

Returns true if the specified unit can execute the specified effect on the specified target unit.

# Arguments

  • unit — Caster
  • string [ gamelink::Effect ] — Effect
  • unit — Target

Returns — bool

bool libNtve_gf_UnitCanCreateEffectOnUnit(
	unit lp_caster,
	string lp_effect,
	unit lp_target,
);

Category: Environment / Effects

# Examples

# mods/starcoop/starcoop.sc2mod

LibCOMI.galaxy

// L3766
libNtve_gf_UnitCanCreateEffectOnUnit(lv_currentattacktargetunit, "ThreatTest", lp_attacker)
// L3783
libNtve_gf_UnitCanCreateEffectOnUnit(lv_bestattacktargetunit, "ThreatTest", lp_attacker)
// L3784
libNtve_gf_UnitCanCreateEffectOnUnit(lv_bestattacktargetunit, "ThreatTest", lp_attacker)
// L13989
libNtve_gf_UnitCanCreateEffectOnUnit(lv_caster, "ObserverTargetLockCPOrderValidate", lv_target)
// L14003
libNtve_gf_UnitCanCreateEffectOnUnit(lv_caster, "ObserverTargetLockCP", lv_target)
// L14036
libNtve_gf_UnitCanCreateEffectOnUnit(lv_caster, "RavenTargetLockCPOrderValidate", lv_target)
// L14050
libNtve_gf_UnitCanCreateEffectOnUnit(lv_caster, "RavenAnalyzeCP", lv_target)
// L27991
libNtve_gf_UnitCanCreateEffectOnUnit(lv_missile, lv_effect, lv_reflectTarget)

# mods/warcoop/warclassic.sc2mod

WarClassic.galaxy

// L144
libNtve_gf_UnitCanCreateEffectOnUnit(lp_unit, "TriggerValidatorUnitIsChanneling", lp_unit)