23.02.2018, 21:16
You didn't do your homework at all this function is incorrect but you can easily find the correct function on the forums.
You are also wasting player textdraws and doing extra work when a lot of them should just be global textdraws.
This does nothing at all.
Code:
Float:GetPlayerSpeed(playerid) { new Float:px, Float:py, Float:pz; GetVehicleVelocity(GetPlayerVehicleID(playerid), px, py, pz); return floatsqroot(floatpower(floatabs(px), 2.0) + floatpower(floatabs(py), 2.0) + floatpower(floatabs(pz), 2.0)) * 100; }
Code:
public OnPlayerDisconnect(playerid, reason) { speedohide(playerid); return 1; }