Player::isJumping: Difference between revisions

From RAGE Multiplayer Wiki
(Created page with "This property returns true or false of player jumping state. == Example == <source lang="javascript"> let playerIsJumping = player.isJumping if (playerIsJumping) player.outp...")
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
This property returns true or false of player jumping state.
This function returns 1 or 0 of player jumping state.
 
'''Note: this property is read-only.'''
== Example ==
== Example ==
<source lang="javascript">
<source lang="javascript">
let playerIsJumping = player.isJumping
let playerIsJumping = player.isJumping()
if (playerIsJumping)
if (playerIsJumping === 1)
   player.outputChatBox('You are jumping right now!');
   player.outputChatBox('You are jumping right now!');
else
else
   player.outputChatBox('You are not jumping right now!');
   player.outputChatBox('You are not jumping right now!');
</source>
</source>
==See Also==
{{Player_block}}

Latest revision as of 22:29, 7 November 2020

This function returns 1 or 0 of player jumping state.

Note: this property is read-only.

Example

let playerIsJumping = player.isJumping()
if (playerIsJumping === 1)
  player.outputChatBox('You are jumping right now!');
else
  player.outputChatBox('You are not jumping right now!');

See Also