Blip::getAlpha: Difference between revisions
MrPancakers (talk | contribs) (Added example & changed layout) |
MrPancakers (talk | contribs) mNo edit summary |
||
| Line 16: | Line 16: | ||
Retrieving the alpha value from the blip called policeBlip | Retrieving the alpha value from the blip called policeBlip | ||
<div class="header" style="background-color: #AE4040; color: #FFFFFF; border: 2px solid #AE4040;"> | |||
<div style="margin: 10px 10px 10px 10px;"><b>Client-Side</b></div> | |||
<syntaxhighlight lang="javascript"> | <syntaxhighlight lang="javascript"> | ||
let policeBlip = mp.blips.new(60, new mp.Vector3(407.95, -961.05, 0), | let policeBlip = mp.blips.new(60, new mp.Vector3(407.95, -961.05, 0), | ||
| Line 29: | Line 31: | ||
//Output: Alpha: 50" | //Output: Alpha: 50" | ||
</syntaxhighlight> | </syntaxhighlight> | ||
</div> | |||
== See Also == | == See Also == | ||
Revision as of 11:01, 11 May 2018
Client-Side
Property to return the alpha value of the blip.
Syntax
blip.getAlpha();
Return Value
- Number
Examples
Retrieving the alpha value from the blip called policeBlip
Client-Side
let policeBlip = mp.blips.new(60, new mp.Vector3(407.95, -961.05, 0),
{
color: 3,
alpha: 50,
shortRange: true,
});
let getBlipAlpha = policeBlip.getAlpha();
mp.gui.chat.push("Alpha:" + getBlipAlpha);
//Output: Alpha: 50"
See Also
- Functions
- Properties