SA-MP Forums Archive
help me pls - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: help me pls (/showthread.php?tid=658307)



help me pls - kevi11 - 01.09.2018

Hi guys can you help me to resolve this error:

warning 202: number of arguments does not match definition



Script:

CMD:b(playerid, params[])
{
if (isnull(params)) return SendClientMessage(playerid, -1, "{C0C0C0}USAGE: /b < message >");

new Float:X, Float:Y, Float:Z, String[128], Name[25];

GetPlayerPos(playerid, X, Y, Z);
GetPlayerName(playerid, Name, 25);

format(String, 128, "(( [%d] %s: %s ))", playerid, Name, params);

for(new i = 0; i < MAX_PLAYERS; i++)
{
if (IsPlayerInRangeOfPoint(i, X, Y, Z))
{
SendClientMessage(playerid, 0xC0C0C0FF, String);
}
}

return true;
}


Re: help me pls - kevi11 - 01.09.2018

I don't understand, pls help me with fix the code.


Re: help me pls - Lokii - 01.09.2018

Quote:
Originally Posted by kevi11
Посмотреть сообщение
I don't understand, pls help me with fix the code.
Код:
if (IsPlayerInRangeOfPoint(i, Float:RANGE, X, Y, Z))
example

Код:
if(IsPlayerInRangeOfPoint(playerid, 20.0, 1200.0, 1400.0, 50.0)) 
{
    SendClientMessage(playerid, -1, "In range");
}
if you still dont understand :

https://y-less.com/uploads/pawn-lang-3.0.3367.pdf //all about pawn
https://sampwiki.blast.hk/wiki/Main_Page //all about samp
https://sampwiki.blast.hk/wiki/IsPlayerInRangeOfPoint //IsPlayerInRangeOfPoint