28.06.2014, 14:42
Quote:
If you find any bugs PM me at foryms.sa-mp.com. |
----
pawn Код:
stock SendRangeMessageToPlayer(playerid, Float:Range, Float:x, Float:y, Float:z, color, text[])
{
if(IsPlayerInRangeOfPoint(playerid,Range,x,y,z))
{
SendClientMessage(i,color,text);
}
}
Fixed one (by me):
pawn Код:
// playerid == prevent the player to send.
// Function name is too long. but you can change it.
stock MessageToPlayersInRangeOfPoint(playerid, Float:x, Float:y, Float:z, Float:range, color, const message[])
{
new
ret = 0;
for(new i = 0; i != MAX_PLAYERS; ++i)
{
if(IsPlayerInRangeOfPoint(i, range, x, y, z) && i != playerid)
{
SendClientMessage(i, color, message);
ret++;
}
}
return ret;
}
----
Why you want to forward Stock functions?
pawn Код:
forward Float:GetPlayerHeightDifference(playerid, heightid);