GetPlayerSpeed
#1

This is what i currently have

pawn Код:
stock GetPlayerSpeed(playerid,bool:kmh)
{
    new Float:Vx,Float:Vy,Float:Vz,Float:rtn;
    if(IsPlayerInAnyVehicle(playerid)) GetVehicleVelocity(GetPlayerVehicleID(playerid),Vx,Vy,Vz); else GetPlayerVelocity(playerid,Vx,Vy,Vz);
    rtn = floatsqroot(floatabs(floatpower(Vx + Vy + Vz,2)));
    return kmh?floatround(rtn * 100 * 1.61):floatround(rtn * 100);
}
What i want:
1: It should calculate in kmh, currently it's mph
2: It should count all numbers, for example 1 kmh, 2 kmh, 3 kmh etc (Currently if i press W it instantly shows 15kmh)

I will give +rep (4points) to the one who helps me!
Reply


Messages In This Thread
GetPlayerSpeed - by Dripac - 01.03.2012, 15:10
Re: GetPlayerSpeed - by iTorran - 01.03.2012, 15:25
Re: GetPlayerSpeed - by Dripac - 01.03.2012, 15:47
Re: GetPlayerSpeed - by milanosie - 01.03.2012, 15:50
Re: GetPlayerSpeed - by Dripac - 01.03.2012, 15:57
Re: GetPlayerSpeed - by Ballu Miaa - 01.03.2012, 16:04
Re: GetPlayerSpeed - by milanosie - 01.03.2012, 16:21
Re: GetPlayerSpeed - by Ballu Miaa - 01.03.2012, 16:24
Re: GetPlayerSpeed - by milanosie - 01.03.2012, 17:34
Re: GetPlayerSpeed - by iPLEOMAX - 01.03.2012, 19:21

Forum Jump:


Users browsing this thread: 5 Guest(s)