# Unit Can Path To Unit
Grammar — unit Can Path To target with range Range and maxDistance Maximum Distance
Flags —Native
|Function
This returns whether or not the unit can path to the specified unit.
# Arguments
unit
— Source Unitunit
— Targetfixed
— Rangefixed
— Max Distance
Returns — bool
native bool UnitPathableToUnit(
unit u,
unit inTarget,
fixed inRange,
fixed inMaxDistance,
);
# Related
Category: Unit / Basic
- [F] —
void
— Unit Show Kill Display — ( UnitShowKillDisplay ) - [F] —
bool
— Unit Can Path To Point — ( UnitPathableToPoint ) - [F] —
bool
— Unit Can Path To Unit — ( UnitPathableToUnit ) - [F] —
void
— Create Units With Default Facing — ( libNtve_gf_CreateUnitsWithDefaultFacing ) - [F] —
void
— Create Units With Point Facing — ( libNtve_gf_CreateUnitsAtPoint2 ) - [F] —
unitgroup
— Create Units Facing Angle — ( UnitCreate ) - [F] —
unitgroup
— Create Units Facing Point — ( libNtve_gf_UnitCreateFacingPoint ) - [F] —
unit
— Last Created Unit — ( UnitLastCreated ) - [F] —
unitgroup
— Last Created Units — ( UnitLastCreatedGroup ) - [F] —
unit
— Original Caster Of Unit — ( UnitGetOriginalCaster ) - [F] —
string
[ gamelink::Effect ] — Effect That Created Unit — ( UnitGetOriginalEffect ) - [F] —
void
— Replace Unit — ( libNtve_gf_ReplaceUnit ) - [F] —
unit
— Last Replaced Unit — ( libNtve_gf_LastReplacedUnit ) - [F] —
void
— Change Owner — ( UnitSetOwner ) - [F] —
void
— Unit Owner Changes — ( TriggerAddEventUnitChangeOwner ) - [F] —
int
— Old Unit Owner — ( EventUnitOwnerOld ) - [F] —
int
— New Unit Owner — ( EventUnitOwnerNew ) - [F] —
void
— Rescue Unit — ( libNtve_gf_RescueUnit ) - [F] —
void
— Rescue Unit Group — ( libNtve_gf_RescueUnit2 ) - [F] —
void
— Kill Unit — ( UnitKill ) - [F] —
void
— Revive Unit — ( UnitRevive ) - [F] —
void
— Remove Unit — ( UnitRemove ) - [F] —
int
— Owner Of Unit — ( UnitGetOwner ) - [F] —
bool
— Unit Is Alive — ( UnitIsAlive ) - [F] —
bool
— Unit Is Valid — ( UnitIsValid ) - [F] —
bool
— Unit Group Is Dead — ( libNtve_gf_UnitGroupIsDead ) - [F] —
void
— Move Unit Instantly — ( UnitSetPosition ) - [F] —
void
— Make Unit Face Angle — ( UnitSetFacing ) - [F] —
void
— Make Unit Face Point — ( libNtve_gf_MakeUnitFacePoint ) - [F] —
point
— Position Of Unit — ( UnitGetPosition ) - [F] —
point
— Goal Position Of Unit — ( UnitGetGoalPosition ) - [F] —
fixed
— Facing Angle Of Unit — ( UnitGetFacing ) - [F] —
void
— Pause/Unpause Unit — ( libNtve_gf_PauseUnit ) - [F] —
void
— Pause/Unpause All Units — ( UnitPauseAll ) - [F] —
void
— Sleep/WakeUp Unit — ( libNtve_gf_SleepUnit ) - [F] —
void
— Show/Hide Unit — ( libNtve_gf_ShowHideUnit ) - [F] —
void
— Share Vision of Unit — ( libNtve_gf_ShareVisionofUnit ) - [F] —
bool
— Unit Is Paused — ( libNtve_gf_UnitIsPaused ) - [F] —
bool
— Unit Is Sleepiing — ( libNtve_gf_UnitIsSleepiing ) - [F] —
bool
— Unit Is Hidden — ( libNtve_gf_UnitIsHidden ) - [F] —
bool
— Unit Is Visible To Player — ( libNtve_gf_UnitIsVisibleToPlayer ) - [F] —
void
— Set Unit Custom Value — ( UnitSetCustomValue ) - [F] —
fixed
— Custom Value Of Unit — ( UnitGetCustomValue ) - [F] —
void
— Unit Enters/Leaves Region — ( TriggerAddEventUnitRegion ) - [F] —
region
— Triggering Region — ( EventUnitRegion ) - [F] —
void
— Unit Enters/Leaves Point — ( TriggerAddEventUnitRangePoint ) - [F] —
void
— Unit Enters/Leaves Range Of Unit — ( TriggerAddEventUnitRange ) - [F] —
unit
— Triggering Range Unit — ( EventUnitRangeUnit ) - [F] —
bool
— Unit In Region — ( libNtve_gf_UnitInRegion ) - [F] —
unit
— Triggering Unit — ( EventUnit ) - [F] —
void
— Load Unit Model — ( UnitLoadModel ) - [F] —
void
— Unload Unit Model — ( UnitUnloadModel ) - [F] —
unit
— Agent Of Player For Unit — ( UnitAgent ) - [F] —
void
— Change Empty Unit Variables In Events — ( UnitEventSetNullVariableInvalid ) - [F] —
text
— Name of Unit — ( UnitGetName ) - [F] —
int
— Ideal Harvester Count — ( UnitIdealWorkerCount ) - [F] —
int
— Current Harvester Count — ( UnitCurrentWorkerCount )
# Examples
# campaigns/void.sc2campaign
// L1090
UnitPathableToUnit(lp_construct, gv_aRTANIS, 0.0, 1000.0)
// L1094
UnitPathableToUnit(lp_construct, gv_kERRIGAN, 0.0, 1000.0)
// L1141
UnitPathableToUnit(lp_crystal, gv_aRTANIS, 0.0, 1000.0)
// L1145
UnitPathableToUnit(lp_crystal, gv_kERRIGAN, 0.0, 1000.0)
// L1268
UnitPathableToUnit(lp_enemyUnit, gv_kERRIGAN, 0.0, 1000.0)
// L1274
UnitPathableToUnit(lp_enemyUnit, gv_aRTANIS, 0.0, 1000.0)
// L1090
UnitPathableToUnit(lp_construct, gv_aRTANIS, 0.0, 1000.0)
// L1094
UnitPathableToUnit(lp_construct, gv_kERRIGAN, 0.0, 1000.0)
// L1141
UnitPathableToUnit(lp_crystal, gv_aRTANIS, 0.0, 1000.0)
// L1145
UnitPathableToUnit(lp_crystal, gv_kERRIGAN, 0.0, 1000.0)
// L1268
UnitPathableToUnit(lp_enemyUnit, gv_kERRIGAN, 0.0, 1000.0)
// L1274
UnitPathableToUnit(lp_enemyUnit, gv_aRTANIS, 0.0, 1000.0)
# mods/heroesdata.stormmod
// L19917
UnitPathableToUnit(lv_misha, lv_rexxar, 0.0, 0.0)
// L19923
UnitPathableToUnit(lv_misha, lv_rexxar, 0.0, 0.0)
# mods/novastoryassets.sc2mod
// L982
UnitPathableToUnit(lp_sporeCrawler, UnitGroupLoopCurrent(), 0.0, 0.0)
// L991
UnitPathableToUnit(lp_sporeCrawler, UnitGroupLoopCurrent(), 0.0, 0.0)
// L982
UnitPathableToUnit(lp_sporeCrawler, UnitGroupLoopCurrent(), 0.0, 0.0)
// L991
UnitPathableToUnit(lp_sporeCrawler, UnitGroupLoopCurrent(), 0.0, 0.0)