{"hash":"0x508F5053E3F6F0C4","ns":"TASK","name":"_IS_PED_LOOKING_AT_COORD","slug":"_IS_PED_LOOKING_AT_COORD","official":false,"named":true,"luaName":"IsPedLookingAtCoord","game":"rdr3","apiset":"client","returnType":"BOOL","params":[{"name":"ped","type":"Ped"},{"name":"x","type":"float"},{"name":"y","type":"float"},{"name":"z","type":"float"},{"name":"radius","type":"float"}],"summary":"Returns true if the ped's current 'IK look-at' target is within `radius` of (x, y, z).","descriptions":[{"source":"alloc8or","format":"text","body":"Returns true if the ped's current 'IK look-at' target is within `radius` of (x, y, z). This checks the active look-at point (head/eyes) not LOS or heading and returns false if the ped has no active look-at target. Typical radius range: 1.0-30.0."},{"source":"vorp","format":"text","body":"Only used in R* SP Scripts\nParams: p4 = 1.0f - 30.0f"}],"examples":[],"aliases":[],"enums":[],"related":[],"build":"1207","sources":["alloc8or","vorp"],"doc":2,"url":"https://natives.borderlinerp.com/natives/TASK/_IS_PED_LOOKING_AT_COORD","markdownUrl":"https://natives.borderlinerp.com/natives/TASK/_IS_PED_LOOKING_AT_COORD.md","snippets":{"lua":"local retval = IsPedLookingAtCoord(ped, x, y, z, radius)","luaInvoke":"local retval = Citizen.InvokeNative(0x508F5053E3F6F0C4, ped, x, y, z, radius, Citizen.ReturnResultAnyway())","js":"const retval = IsPedLookingAtCoord(ped, x, y, z, radius);","jsInvoke":"const retval = Citizen.invokeNative('0x508F5053E3F6F0C4', ped, x + 0.0000001, y + 0.0000001, z + 0.0000001, radius + 0.0000001, Citizen.returnResultAnyway());","csharp":"bool retval = Function.Call<bool>((Hash)0x508F5053E3F6F0C4, ped, x, y, z, radius);","notes":["Float parameters: Lua integers (`10`, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write `10.0` or `value + 0.0`. The generated JS wrappers add `0.0000001` to non-zero floats for the same reason.","The name is a community guess and may change. If the named call is missing in your client build, use `InvokeNative` with the hash — it always works."]}}