Author Topic: Need help with speedometer.  (Read 3116 times)

0 Members and 1 Guest are viewing this topic.

Offline Jancis71

  • Street Thug
  • *
  • Posts: 21
    • View Profile
Need help with speedometer.
« on: August 05, 2010, 03:05:38 pm »
code:

@ OnGameModeInit: SetTimer("Speed",250,1);

Code: [Select]
public Speed()
{
for(new i = 0; i <= USERCOUNT; i++)
    {
        if(IsPlayerConnected(i))
{
new Float:x, Float:y, Float:z, distance,result,resultx[256];
    x=PlayerInfo[i][PosX];
y=PlayerInfo[i][PosY];
z=PlayerInfo[i][PosZ];
distance=GetDistance(i, x, y, z);
result=distance*6;
 format(resultx,256,"%dkm/h",result);
GameTextForPlayerBottom(i,resultx);

new Float:x2,Float:y2,Float:z2;
GetPlayerPos(i,x2,y2,z2);
PlayerInfo[i][PosX]=x2;
PlayerInfo[i][PosY]=y2;
PlayerInfo[i][PosZ]=z2;

}

}
}

but function is not working well, it needs improvements.
sorry for my english.

Offline Tonys

  • Street Thug
  • *
  • Posts: 19
    • View Profile
Re: Need help with speedometer.
« Reply #1 on: August 05, 2010, 04:53:14 pm »
Check your PM, the one I sent you should work without problems.

Offline MISHA123152

  • Street Thug
  • *
  • Posts: 46
    • View Profile
    • Russian Server
Re: Need help with speedometer.
« Reply #2 on: August 28, 2010, 10:02:11 pm »
please write her answer... how can i do speedometer?

Offline Madara

  • Street Thug
  • *
  • Posts: 48
    • View Profile
Re: Need help with speedometer.
« Reply #3 on: August 29, 2010, 12:25:23 am »
What is your server?