Blip::setColour: Difference between revisions

From RAGE Multiplayer Wiki
m (Mcfloy moved page Blip::setColour to Blip::setColor)
No edit summary
Line 1: Line 1:
Color:<br><br>0: white<br>1: red<br>2: green<br>3: blue<br>17: orange<br>19: purple<br>20: grey<br>21: brown<br>23: pink<br>25: dark green<br>27: dark purple<br>29: dark blue<br>Default (Function not used): yellow<br><br>Those are not the only ones. i.e: 17 is Trevor's orange.
Function to set a blip color. Default to yellow if not used.
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">blip.setColour(color);</syntaxhighlight>
<syntaxhighlight lang="javascript">blip.setColour(color);</syntaxhighlight>
=== Required Arguments ===
===Required Argument===
*'''color:''' int
* '''color:''' {{RageType|Number}} [[Blips#Blip_colors|color list]]
===Return value===
===Return value===
*'''Undefined'''
* '''Undefined'''
==Example==
==Example==
{{ClientsideCode|
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
// todo
let blip = mp.blips.new(1, new mp.Vector3(407.95, -961.05, 0));
blip.setColour(1); // Set blip color to red
</syntaxhighlight>
</syntaxhighlight>
}}
==See also==
==See also==
{{Blip_s_function_c}}
{{Blip_s_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:Blip API]]
[[Category:Blip API]]
[[Category:TODO: Example]]
[[Category:Client-side Function]]

Revision as of 08:55, 6 May 2019