HUDClient

addBlipForArea

ADD_BLIP_FOR_AREA0xCE5D0E5E315DB238

The GTA V native ADD_BLIP_FOR_AREA of the HUD namespace, as LS:MP client scripts call it: the global function addBlipForArea, in JavaScript and in Lua.

SignatureJavaScript
addBlipForArea(
  x: number,
  y: number,
  z: number,
  width: number,
  height: number
): Blip
SignatureLua
addBlipForArea(
  x: number,
  y: number,
  z: number,
  width: number,
  height: number
): Blip

Usage

JavaScript
const blip = addBlipForArea(x, y, z, width, height);
Lua
local blip = addBlipForArea(x, y, z, width, height)

Three consecutive numbers can be given as one vector: { x, y, z } (or [x, y, z]) in JavaScript, a Vector3 in Lua.

JavaScript · with vectors
const blip = addBlipForArea(pos, width, height);
Lua · with vectors
local blip = addBlipForArea(pos, width, height)

Parameters

ParameterTypeJavaScriptLua
xfloatnumbernumber
yfloatnumbernumber
zfloatnumbernumber
widthfloatnumbernumber
heightfloatnumbernumber

Returns

Blip JavaScript number, Lua integer

Handle of a map blip.

Notes

From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.

Adds a rectangular blip for the specified coordinates/area.

It is recommended to use setBlipRotation and setBlipColour to make the blip not rotate along with the camera.

By default, the blip will show as a _regular_ blip with the specified color/sprite if it is outside of the minimap view.

Reference

Namespace
HUD HUD
In the game
Blip ADD_BLIP_FOR_AREA(float x, float y, float z, float width, float height)
Hash
0xCE5D0E5E315DB238
Introduced
Game build 463 legacy numbering
Formerly
_ADD_BLIP_FOR_AREA

Open in the interactive natives reference