Problem dcmd! - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Problem dcmd! (
/showthread.php?tid=254100)
Problem dcmd! -
Admigo - 09.05.2011
Hee guys
I have lots of dcmd codes in my script and all they work and no errors.
But when i add another cmd: dcmd(response, 8, cmdtext); it says:
Код:
C:\Users\....\Desktop\GTA San Andreas\gamemodes\coanro2.pwn(3540) : warning 202: number of arguments does not match definition
C:\Users\....\Desktop\GTA San Andreas\gamemodes\coanro2.pwn(3540) : warning 202: number of arguments does not match definition
How can i fix this?
Thanks Admigo
Re: Problem dcmd! -
Skaizo - 09.05.2011
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
dcmd(response, 7, cmdtext);
try this
Re: Problem dcmd! -
Admigo - 09.05.2011
Quote:
Originally Posted by [RSS]Cops_sandu
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[]) { dcmd(response, 7, cmdtext);
try this
|
Sorry dont work:S Same errors!
Re: Problem dcmd! -
Admigo - 09.05.2011
Have i reached the maximum dcmd commands?
Re: Problem dcmd! -
Admigo - 09.05.2011
Pls nobody? I need to fix this!
Re: Problem dcmd! -
Sinner - 09.05.2011
try this
pawn Код:
dcmd_response(playerid, params[])
{
#pragma unused params
/*
* YOUR CODE HERE
*
*/
return 1;
}
Also, "response" has 8 characters, not 7, so do
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
dcmd(response, 8, cmdtext);
return 0;
}
#pragma unused params = ignore the "params" parameter,
only use this if you aren't using params
Re: Problem dcmd! -
Admigo - 09.05.2011
Quote:
Originally Posted by Sinner
try this
pawn Код:
dcmd_response(playerid, params[]) { #pragma unused params
/* * YOUR CODE HERE * */ return 1; }
Also, "response" has 8 characters, not 7, so do
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[]) { dcmd(response, 8, cmdtext); return 0; }
#pragma unused params = ignore the "params" parameter, only use this if you aren't using params
|
OMG FIXED,Thank you so much!
Re: Problem dcmd! -
Sinner - 09.05.2011
Quote:
Originally Posted by admigo
OMG FIXED,Thank you so much!
|
No problem