SA-MP Forums Archive
warning help - 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: warning help (/showthread.php?tid=555101)



warning help - Rabea - 06.01.2015

when i add return SendClientMessage blablabla its giving me this warning

pawn Код:
(8259) : warning 202: number of arguments does not match definition
this an example code.
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 6, 294.3638,-82.5354,1001.5156,90.4606)) return SendClientMessage(playerid, COLOR_GREY, "You are not near the ammunation rob point.");
Thanks for helping.


Re: warning help - HY - 06.01.2015

Actually, you have this:

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 6, 294.3638,-82.5354,1001.5156,90.4606)) return SendClientMessage(playerid, COLOR_GREY, "You are not near the ammunation rob point.");
You have 6 arguments. You need only 5.

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, Range, X, Y, Z)) return SendClientMessage(playerid, COLOR_GREY, "You are not near the ammunation rob point.");
You put Angle too. I think..
Correct code:

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 6, 294.3638,-82.5354,1001.5156)) return SendClientMessage(playerid, COLOR_GREY, "You are not near the ammunation rob point.");



Re: warning help - Rabea - 06.01.2015

Thanks! +rep <3


Re: warning help - Rabea - 06.01.2015

and what about this line? same error
pawn Код:
GameTextForPlayer(playerb, "~w~You has been unsuspected by %s, you are not a criminal anymore !", 5000, 3, NORPN(playerid));



Re: warning help - Sid_Alexander - 06.01.2015

Quote:
Originally Posted by Rabea
Посмотреть сообщение
and what about this line? same error
pawn Код:
GameTextForPlayer(playerb, "~w~You has been unsuspected by %s, you are not a criminal anymore !", 5000, 3, NORPN(playerid));
pawn Код:
new string[128];
format(string, sizeof(string), "~w~You has been unsuspected by %s, you are not a criminal anymore !",NORPN(playerid));
GameTextForPlayer(playerb, string, 5000, 3);



Re: warning help - HY - 06.01.2015

Can't use GameTextForPlayer like this.
Format it;

pawn Код:
new string[50];
format(string, sizeof(string), "~w~You has been unsuspected by %s, you are not a criminal anymore !", NORPN(playerid));
GameTextForPlayer(playerid, string, 5000, 3);



Re: warning help - Rabea - 06.01.2015

its giving the same error