Z4Zy Posted January 10, 2020 Share Posted January 10, 2020 Hello everyone ! When I use following piece of code to set the animation and get what animation the ped is doing, I've noticed that 'getPedAnimation' function doesn't return the correct animation when 'setPedAnimation' function's loop argument set to false. When loop argument set to true, 'getPedAnimation' function return the correct block and animation. I used IFP_Demo resource's parkour.ifp file. Client Side : local ifp = engineLoadIFP("parkour.ifp", "parkour") setPedAnimation(localPlayer, "parkour", "HandPlant", -1, false) -- set false argument to true when testing setTimer( function () local block, anim = getPedAnimation(localPlayer) outputDebugString("Block : "..block..", Anim : "..anim) end, 1000, 1 ) When 'setPedAnimation' function's loop argument set to false, Spoiler INFO message has return the wrong block and animation. When 'setPedAnimation' function's loop argument set to true, Spoiler INFO message has return the correct block and animation. Link to comment
Moderators Patrick Posted January 10, 2020 Moderators Share Posted January 10, 2020 I think because the animation ends after 1 minute but freezeLastFrame is enabled. So, the animation is no longer running, it just seems. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now