Quote:
Originally Posted by GSantana
PHP код:
stock GetPlayerSpeed(playerid)
{
new Float:ST[4];
if(IsPlayerInAnyVehicle(playerid))
GetVehicleVelocity(GetPlayerVehicleID(playerid),ST[0],ST[1],ST[2]);
else GetPlayerVelocity(playerid,ST[0],ST[1],ST[2]);
ST[3] = floatsqroot(floatpower(floatabs(ST[0]), 2.0) + floatpower(floatabs(ST[1]), 2.0) + floatpower(floatabs(ST[2]), 2.0)) * 118.3;
return floatround(ST[3]);
}
ai й sу tu usar um timer para verificar a velocidade do player tipo
PHP код:
if(ST[3] >= 110)
{
//oque vai acontecer aqui
}
|
Eu so nгo entendo pq *118,3, alguem me explica?