Blip::isOnMinimap: Difference between revisions

From RAGE Multiplayer Wiki
No edit summary
No edit summary
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
 
Function to return whether the blip is visible on client's minimap.
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">blip.isOnMinimap(blip);</syntaxhighlight>
<syntaxhighlight lang="javascript">blip.isOnMinimap();</syntaxhighlight>
=== Required Arguments ===
*'''blip:''' Blip
===Return value===
===Return value===
*'''Boolean'''
* {{RageType|Boolean}}
==Example==
==Example==
{{ClientsideCode|
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
// todo
let my = mp.players.local;
let policeBlip = mp.blips.new(60, my.position); // Create police blip on player location so it's visible on their map
 
let isBlipVisible = policeBlip.isOnMinimap();
mp.gui.chat.push("Is blip visible? " + isBlipVisible ); // Output: "Is blip visible? true"
</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]]

Latest revision as of 08:36, 6 May 2019