Animation ID of taking out an item? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Animation ID of taking out an item? (
/showthread.php?tid=641471)
Animation ID of taking out an item? -
Meller - 16.09.2017
I really can't remember if this was GTA V or GTA SA, but what's the ped animation that happens when you withdraw a weapon in the single player?
Re: Animation ID of taking out an item? -
Eoussama - 16.09.2017
I use the block animation, I find it the closest:
PHP код:
ApplyAnimation(playerid, "PED", "FIGHTA_BLOCK", 4.1, 0, 0, 0, 0, 480, 1);
One thing tho! If the animation was applied while the player is running, they won't be able to stop until the animation is finished, it can be really bad in situations where you might fall from high places.
Re: Animation ID of taking out an item? -
cuber - 16.09.2017
WEAPONS(idk if any of these will help you tho)
SHP_1H_Lift
SHP_1H_Lift_End
SHP_1H_Ret
SHP_1H_Ret_S
SHP_2H_Lift
SHP_2H_Lift_End
SHP_2H_Ret
SHP_2H_Ret_S
SHP_Ar_Lift
SHP_Ar_Lift_End
SHP_Ar_Ret
SHP_Ar_Ret_S
SHP_G_Lift_In
SHP_G_Lift_Out
SHP_Tray_In
SHP_Tray_Out
SHP_Tray_Pose
Re: Animation ID of taking out an item? -
Meller - 16.09.2017
Quote:
Originally Posted by Eoussama
I use the block animation, I find it the closest:
PHP код:
ApplyAnimation(playerid, "PED", "FIGHTA_BLOCK", 4.1, 0, 0, 0, 0, 480, 1);
One thing tho! If the animation was applied while the player is running, they won't be able to stop until the animation is finished, it can be really bad in situations where you might fall from high places.
|
Hm, gonna try getting the sprint status by their velocity and then apply the animation? I.e:
PHP код:
new Float:x, Float:y, Float:z, Float:units;
GetPlayerVelocity(playerid, x, y, z);
if(floatsqroot(floatabs(floatpower(x + y + z, 2.0))) < 0.1552086)
//apply anim
Note that I might have calculated horribly wrong.