Skip to main content

GET_CLOSEST_ROAD

Game.GetClosestRoadHash0x63C00DE7
Usage
local closestRoad, southEndNodeX, southEndNodeY, southEndNodeZ, northEndNodeX, northEndNodeY, northEndNodeZ, lanesGoingSouth, lanesGoingNorth, centralReservationWidth = Game.GetClosestRoad(x, y, z, minLength, minLanes)

Will return if can the closest road segment of a certein length with a certain number of lanes.

Parameters

  • xnumberfloat
  • ynumberfloat
  • znumberfloat
  • minLengthnumberfloat
  • minLanesintegerint

Returns

  • closestRoadbooleanreturn value
  • southEndNodeXnumberVector3*
  • southEndNodeYnumberVector3*
  • southEndNodeZnumberVector3*
  • northEndNodeXnumberVector3*
  • northEndNodeYnumberVector3*
  • northEndNodeZnumberVector3*
  • lanesGoingSouthintegerint*
  • lanesGoingNorthintegerint*
  • centralReservationWidthnumberfloat*
Original declaration
// 0x63C00DE7
bool GET_CLOSEST_ROAD(float x, float y, float z, float minLength, int minLanes, Vector3* southEndNode, Vector3* northEndNode, int* lanesGoingSouth, int* lanesGoingNorth, float* centralReservationWidth);