# Lane Waypoint Calc Closest Data For Lane
Flags —
Native
|Action
Calculates a handful of data for the closest point in the given TestLane to point TestPoint. Query the calculated data with the “Lane Waypoint Get Calc Data ___” functions.
# Arguments
int
— TestLanepoint
— TestPoint
Returns — void
native void AILaneWaypointCalcClosestDataForLane(
int testLane,
point testPoint,
);
# Related
Category: AI Advanced / Lane / Actions
- Lane Waypoint Clear All —
void
— AILaneWaypointClearAll - Lane Waypoint Add —
void
— AILaneWaypointAdd - Lane Waypoint Calc Closest Data For Lane —
void
— AILaneWaypointCalcClosestDataForLane
# Examples
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameLib.galaxy:8190
// Implementation
AILaneWaypointCalcClosestDataForLane(lp_curLane, lp_testPoint);
libGame_gv_closestLaneData.lv_laneData[lp_curLane].lv_closestIndex = AILaneWaypointGetCalcDataClosestWaypointIndex();
libGame_gv_closestLaneData.lv_laneData[lp_curLane].lv_secondaryIndex = AILaneWaypointGetCalcDataSecondWaypointIndex();