Player::setEnableScuba: Difference between revisions

From RAGE Multiplayer Wiki
(yay)
 
m (Updated page)
 
Line 1: Line 1:
Enables diving motion when underwater.
__NOTOC__
{{ClientsideJsFunction}}
When enabled, will change the style of your swimming when underwater.
 
'''NOTE''': This does not apply any scuba gear. This must be done using the appropriate functions.
 
{{JSContainer|
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">player.setEnableScuba(toggle);</syntaxhighlight>
<pre>player.setEnableScuba(toggle);</pre>
 
=== Required Arguments ===
=== Required Arguments ===
*'''toggle:''' Boolean
*'''toggle:''' Boolean
===Return value===
 
*'''Undefined'''
==Example==
==Example==
<syntaxhighlight lang="javascript">
{{ClientsideCode|
// todo
<pre>
</syntaxhighlight>
mp.players.local.setEnableScuba(true);
</pre>
}}
}}
==See also==
==See also==
{{Player_function_c}}
{{Player_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:TODO: Example]]
[[Category:TODO: Example]]

Latest revision as of 11:31, 18 July 2021

Client-Side
Function

 JavaScript



When enabled, will change the style of your swimming when underwater.

NOTE: This does not apply any scuba gear. This must be done using the appropriate functions.

JavaScript Syntax

Syntax

player.setEnableScuba(toggle);

Required Arguments

  • toggle: Boolean

Example

Client-Side
mp.players.local.setEnableScuba(true);


See also