SixL client API / world-entities / BlipMpPool
Interface: BlipMpPool
The pool of blips: mp.blips. It holds the blips the server has sent to this client now.
Example
mp.blips.forEach((blip) => mp.console.logInfo(String(blip.sprite)));
Properties
colours
readonlycolours:Readonly<Record<"yellow"|"gold"|"amber"|"red"|"green"|"blue"|"cyan"|"teal"|"pink"|"lavender"|"crimson"|"white",number>>
The VI blip colours by appearance: yellow, gold, amber, red, green, blue, cyan, teal, pink, lavender, crimson, white. Each is a VI blip modifier key for a blip's setColour; the same table as the server's mp.blips.colours. Read only.
Remarks
SixL-only. These are VI's own measured colours, not GTA V's: RAGE MP colour ids are not translated.
Example
blip.setColour(mp.blips.colours.cyan);
length
readonlylength:number
The number of blips the client holds now.
Example
const count = mp.blips.length;
Methods
at()
at(id):BlipMp
The blip with this client id, or undefined.
Parameters
id
number
The client's own number for the blip (from 1, reused after a blip is removed). It is not the server's id.
Returns
The blip, or undefined when there is none with that id.
Example
const blip = mp.blips.at(1);
exists()
exists(entity):boolean
Whether a blip is still held by this client.
Parameters
entity
number | BlipMp
A blip, or the client id of one (the id of BlipMpPool.at).
Returns
boolean
True while the blip is held; false once the server has removed it from this client.
Example
if (mp.blips.exists(blip)) { }
forEach()
forEach(callingFunction):void
Calls a function for every blip held by this client.
Parameters
callingFunction
(entity) => void
Called with each blip.
Returns
void
Example
mp.blips.forEach((blip) => mp.console.logInfo(String(blip.handle)));
toArray()
toArray(): BlipMp[]
The blips held by this client, as an array.
Returns
BlipMp[]
A new array of the blips at the time of the call.
Example
const all = mp.blips.toArray();