Player::setPlayerInvincible: Difference between revisions

From RAGE Multiplayer Wiki
(yay)
 
(yay)
Line 1: Line 1:
Simply sets you as invincible (Health will not deplete).<br><br>Use 0x733A643B5B0C53C1 instead if you want Ragdoll enabled, which is equal to:<br>*(DWORD *)(playerPedAddress + 0x188) |= (1 &lt;&lt; 9);
Simply sets you as invincible (Health will not deplete).<br><br>Use 0x733A643B5B0C53C1 instead if you want Ragdoll enabled, which is equal to:<br>*(DWORD *)(playerPedAddress + 0x188) |= (1 &lt;&lt; 9);
==Syntax==
==Syntax==
<syntaxhighlight lang="javascript">player.setPlayerInvincible(toggle);</syntaxhighlight>
<syntaxhighlight lang="javascript">mp.game.player.setPlayerInvincible(toggle);</syntaxhighlight>
=== Required Arguments ===
=== Required Arguments ===
*'''toggle:''' Boolean
*'''toggle:''' Boolean
Line 8: Line 8:
==Example==
==Example==
<syntaxhighlight lang="javascript">
<syntaxhighlight lang="javascript">
todo
// todo
</syntaxhighlight>
</syntaxhighlight>
==See also==
==See also==
{{Player_function_c}}
{{Player_s_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:TODO: Example]]
[[Category:TODO: Example]]

Revision as of 21:29, 6 May 2017

Simply sets you as invincible (Health will not deplete).

Use 0x733A643B5B0C53C1 instead if you want Ragdoll enabled, which is equal to:
*(DWORD *)(playerPedAddress + 0x188) |= (1 << 9);

Syntax

mp.game.player.setPlayerInvincible(toggle);

Required Arguments

  • toggle: Boolean

Return value

  • Undefined

Example

// todo

See also