Cursor.show: Difference between revisions

From RAGE Multiplayer Wiki
m (Replaced HTML with template)
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
Show or hide the cursor on your screen
Show or hide the cursor on your screen
==Syntax==
==Syntax==
{{ClientSide}}
{{ClientsideCode|
<syntaxhighlight lang="javascript">
<pre>
mp.gui.cursor.show(freezeControls, visibility);
mp.gui.cursor.show(freezeControls, visibility);
</syntaxhighlight>
</pre>
}}


===Required arguments===
===Required arguments===
Line 11: Line 13:


==Example==
==Example==
<div class="header" style="background-color: #AE4040; color: #FFFFFF; border: 2px solid #AE4040;">
{{ClientsideCode|
<div style="margin: 10px 10px 10px 10px;"><b>Client-Side</b></div>
<pre>
<syntaxhighlight lang="javascript">
mp.gui.cursor.show(true, true); //Disables the players controls and shows the cursor
mp.gui.cursor.show(true, true); //Shows the cursor and disables the players controls
</pre>
</syntaxhighlight>
}}
</div>


==See also==
==See also==
{{Gui_definition_c}}
{{Gui_definition_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]

Latest revision as of 12:50, 26 October 2018

Show or hide the cursor on your screen

Syntax

Client-Side
mp.gui.cursor.show(freezeControls, visibility);

Required arguments

  • freezeControls: boolean
  • visibility: boolean

Example

Client-Side
mp.gui.cursor.show(true, true); //Disables the players controls and shows the cursor

See also