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



Errors - SkaiPeretz - 02.05.2014

Код:
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(12892) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(14373) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(14456) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(14564) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(15944) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16033) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16106) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16180) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16270) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16377) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16444) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16500) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16552) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16636) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16719) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16802) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16884) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(16974) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17064) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17147) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17232) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17308) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17377) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17454) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17660) : error 035: argument type mismatch (argument 1)
C:\Users\MOTI\Desktop\ъйчйд згщд\gamemodes\cnr.pwn(17767) : error 035: argument type mismatch (argument 1)

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


26 Errors.
PHP код:
Lines that have errors
giveplayerid ReturnUser (playeridtmp); 
PHP код:
Which is the complete code of the lines where the damned 
/ / Between This Brace Is What Happens When A Player Types A Playerid 
if (! isNumeric (tmp)) 
{
giveplayerid ReturnUser (playeridtmp); 
if (
giveplayerid == INVALID_PLAYER_ID
{
return 
1


else 
{
giveplayerid strval (tmp); 
if (! 
IsPlayerConnected (giveplayerid)) 
{
format (stringsizeof (string), "% d Is Not A Valid ID."giveplayerid); 
SendClientMessage (playeridCOLOR_ERRORstring); 
return 
1


/ / 
Between This Brace Is What Happens When A Player Types A Playerid 




Re: Errors - Konstantinos - 02.05.2014

The first argument should be array and the second (optional) integer. So I guess it's:
pawn Код:
giveplayerid = ReturnUser(tmp, playerid);
But.. ReturnUser is an old function and you shouldn't use it. Give a try at sscanf which is faster, better and it can be used for many other reasons.

A documentation can be found: https://sampforum.blast.hk/showthread.php?tid=120356


Re: Errors - SkaiPeretz - 02.05.2014

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
The first argument should be array and the second (optional) integer. So I guess it's:
pawn Код:
giveplayerid = ReturnUser(tmp, playerid);
But.. ReturnUser is an old function and you shouldn't use it. Give a try at sscanf which is faster, better and it can be used for many other reasons.

A documentation can be found: https://sampforum.blast.hk/showthread.php?tid=120356
no working....


Re: Errors - Konstantinos - 02.05.2014

As you can see, there are 26 errors. By changing it to only the line I posted will not fix the other 25.
But still, switching to sscanf is the best suggestion I can give you.


Re: Errors - SkaiPeretz - 03.05.2014

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
As you can see, there are 26 errors. By changing it to only the line I posted will not fix the other 25.
But still, switching to sscanf is the best suggestion I can give you.
Dude how do I fix it?


Re: Errors - SkaiPeretz - 03.05.2014

more pliz!!!!


Re: Errors - SkaiPeretz - 03.05.2014

moreeee help pliz