Vehicle::isCopVehicleInArea3d: Difference between revisions

From RAGE Multiplayer Wiki
(yay)
 
(yay)
 
Line 1: Line 1:
Usage:<br><br>public bool isCopInRange(Vector3 Location, float Range)<br>        {<br>            return Function.Call&lt;bool&gt;(Hash.IS_COP_PED_IN_AREA_3D, Location.X - Range, Location.Y - Range, Location.Z - Range, Location.X + Range, Location.Y + Range, Location.Z + Range);<br>        }
Usage:<br><br>public bool isCopInRange(Vector3 Location, float Range)<br>        {<br>            return Function.Call&lt;bool&gt;(Hash.IS_COP_PED_IN_AREA_3D, Location.X - Range, Location.Y - Range, Location.Z - Range, Location.X + Range, Location.Y + Range, Location.Z + Range);<br>        }
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">vehicle.isCopVehicleInArea3d(x1, x2, y1, y2, z1, z2);</syntaxhighlight>
<syntaxhighlight lang="javascript">mp.game.vehicle.isCopVehicleInArea3d(x1, x2, y1, y2, z1, z2);</syntaxhighlight>
=== Required Arguments ===
=== Required Arguments ===
*'''x1:''' float
*'''x1:''' float
Line 13: Line 13:
==Example==
==Example==
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
todo
// todo
</syntaxhighlight>
</syntaxhighlight>
==See also==
==See also==
{{Vehicle_function_c}}
{{Vehicle_s_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:TODO: Example]]
[[Category:TODO: Example]]

Latest revision as of 21:34, 6 May 2017

Usage:

public bool isCopInRange(Vector3 Location, float Range)
{
return Function.Call<bool>(Hash.IS_COP_PED_IN_AREA_3D, Location.X - Range, Location.Y - Range, Location.Z - Range, Location.X + Range, Location.Y + Range, Location.Z + Range);
}

Syntax

mp.game.vehicle.isCopVehicleInArea3d(x1, x2, y1, y2, z1, z2);

Required Arguments

  • x1: float
  • x2: float
  • y1: float
  • y2: float
  • z1: float
  • z2: float

Return value

  • Boolean

Example

// todo

See also