Can Somebody tell me what are those mean?
#1

pawn Код:
#define SendFormattedText(%1,%2,%3,%4) do{ new string[128]; format(string,sizeof(string),(%3),%4); SendClientMessage((%1),(%2),string); }while(FALSE)
pawn Код:
new Float:Dis = floatsqroot(floatpower(floatabs(floatsub(OldCoordsX[i],x)),2) + floatpower(floatabs(floatsub(OldCoordsY[i],y)),2));
Reply
#2

The first one is a quick formatted message, it's the same as:
pawn Код:
new string[128];
format(string, sizeof(string), "hello %d!", playerid);
SendClientMessage(playerid, -1, string);
The second one is a calculated distance, it creates a little equation that gives you the distance from points.
In the method you've showed us, it calculates the distance between a 2D space, OldCoordsX[i], x and OldCoordsY[i], y.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)