Player::stopAnimation: Difference between revisions

From RAGE Multiplayer Wiki
Line 4: Line 4:


==Syntax==
==Syntax==
{{ServersideCode|
<pre>
<pre>
player.stopAnimation()
player.stopAnimation()
</pre>
</pre>
}}


==Example==
==Example==

Revision as of 23:32, 23 April 2019

This method stops animation of the player

Parameters

None

Syntax

player.stopAnimation()

Example

Server-Side
// call this events from client side to do animation for 10s and stop it

mp.events.add("DoMedicalCheck", (player) => {
    player.taskStartScenarioInPlace('CODE_HUMAN_MEDIC_KNEEL', 0, true)
    setTimeout(() => {
        player.stopAnimation()
    }, 10000)
})

See Also