Blip::Blip: Difference between revisions
| Line 35: | Line 35: | ||
<syntaxhighlight lang="javascript"> | <syntaxhighlight lang="javascript"> | ||
let policeBlipVector = new mp.Vector3(408.4915466308594, -979.883056640625, 29.22386360168457); //Set a Vector3 | let policeBlipVector = new mp.Vector3(408.4915466308594, -979.883056640625, 29.22386360168457); //Set a Vector3 | ||
let userBlip = mp.blips.new(8, policeBlipVector); //Create a Blip on a Policestation | let userBlip = mp.blips.new(8, policeBlipVector, { | ||
name: "Police", | |||
scale: 2, | |||
color: 7, | |||
alpha: 255, | |||
drawDistance: 100, | |||
shortRange: true, | |||
rotation: 0, | |||
dimension: 0, | |||
}); //Create a Blip on a Policestation | |||
</syntaxhighlight> | </syntaxhighlight> | ||
==See Also== | ==See Also== | ||
{{Blip_definition}} | {{Blip_definition}} | ||
Revision as of 15:40, 14 January 2018
Function: Creates a blip.
Parameters
- sprite: Int (Blip sprites)
- position: Vector3
- name: String
- scale: Float
- color: Color ID (Blip colors)
- alpha: Int [0:255]
- drawDistance: Float
- shortRange: Boolean: Auto-hide on the minimap
- rotation: Vector3
- dimension: Int
Syntax
mp.blips.new(sprite, position,
{
name: name,
scale: scale,
color: color,
alpha: alpha,
drawDistance: drawDistance,
shortRange: shortRange,
rotation: rotation,
dimension: dimension,
});
Example
Shared
let policeBlipVector = new mp.Vector3(408.4915466308594, -979.883056640625, 29.22386360168457); //Set a Vector3
let userBlip = mp.blips.new(8, policeBlipVector, {
name: "Police",
scale: 2,
color: 7,
alpha: 255,
drawDistance: 100,
shortRange: true,
rotation: 0,
dimension: 0,
}); //Create a Blip on a Policestation
See Also
- Functions
- Properties