06.03.2015, 06:04
Hey guys,
I have a question, how can i make a player speed very low whenever he is falling?
I have a question, how can i make a player speed very low whenever he is falling?
Use GetPlayerVelocity to check if his z angle is dropping too fast while not in any vehicle.
Then use SetPlayerVelocity to set his speed to something slower. |
new Float:x, Float:y, Float:z;
GetPlayerVelocity(playerid, x, y, z);
if(z < -5) SetPlayerVelocity(playerid, x, y, -2); // Checks if the z speed is lower than -5, so it's etc. -6
// If so, sets his z velocity to -2
Something like this maybe:
pawn Код:
|
if(z < -5) SetPlayerVelocity(playerid, x, y, -2); // Checks if the z speed is lower than -5, so it's etc. -6