Blip::getAlpha: Difference between revisions

From RAGE Multiplayer Wiki
No edit summary
(Added example & changed layout)
Line 1: Line 1:
{{ClientSide}}
Property to return the alpha value of the blip.
== Syntax ==


==Syntax==
<syntaxhighlight lang="javascript">blip.getAlpha();</syntaxhighlight>
===Return value===
*'''int'''
==Example==
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
// todo
blip.getAlpha();
</syntaxhighlight>
</syntaxhighlight>
==See also==
 
{{Blip_s_function_c}}
=== Return Value ===
*'''Number'''
 
== Examples ==
 
Retrieving the alpha value from the blip called policeBlip
 
<syntaxhighlight lang="javascript">
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"
</syntaxhighlight>
 
== See Also ==
{{Blip_definition}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:Blip API]]
[[Category:Blip API]]
[[Category:TODO: Example]]

Revision as of 10:57, 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

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