25.02.2012, 21:09
Fijate si te sirve:
pawn Код:
new Float: KMH;
new Float: Xa;
new Float: Ya;
new Float: Za;
new Float: Xb[MAX_PLAYERS];
new Float: Yb[MAX_PLAYERS];
new Float: Zb[MAX_PLAYERS];
pawn Код:
GetPlayerPos(i,Xa,Ya,Za);
KMH = floatsqroot(floatpower(floatabs(floatsub(Xa,Xb[i])),2)+floatpower(floatabs(floatsub(Ya,Yb[i])),2)+floatpower(floatabs(floatsub(Za,Zb[i])),2));
KMH *= 10.2;