02.03.2012, 08:12
maybe you can use this? XD dont know if this is what you mean
i dont know if the time of timer is right but you could make something like this.
EDIT: you could also use this to get the speed of the player:
pawn Код:
SetTimer("10kph", 500, 1);
forward 10kph();
public 10kph()
{
GivePlayerMoney(playerid, -250);
return 1;
}
EDIT: you could also use this to get the speed of the player:
pawn Код:
stock GetPlayerSpeed(playerid, bool:kmh) // by misco
{
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);
}