setPedAnimationSpeed | Multi Theft Auto: Wiki Skip to content

setPedAnimationSpeed

Client-side
Server-side
Shared

This page is incomplete! Help wanted!

Please finish this page using the corresponding Old Wiki article.
Go to Contribution guidelines for more information.


Sets the speed of a currently running animation for a particular player or ped.

Important

Warning: Setting speed higher than 1 can cause issues with some animations.

Syntax

setPedAnimationSpeed ( )

Code Examples

server

In this example we give the animation of dancing to the player and after 5 seconds it becomes 0.2s slower.

addCommandHandler('dance',
function( player, cmd )
setPedAnimation( player, 'DANCING', 'DAN_Down_A', -1 )
setTimer(function(plr)
if isElement(plr) then setPedAnimationSpeed( plr, 'DAN_Down_A', 0.2 ) end
end,5000,1,player)
end
)

See Also