SA-MP Forums Archive
DCMD WINS [SOLVED] - 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: DCMD WINS [SOLVED] (/showthread.php?tid=143433)



DCMD WINS [SOLVED] - IamNotKoolllll - 22.04.2010

//includes
#include <a_samp>
#include <dini>
#include <dutils>
#include <dudb>
//pragma
#pragma unused ret_memcpy
//forwards
forward autofix();
//new
//dcmd
#define dcmd(%1,%2,%3) if (!strcmp((%3)[1], #%1, true, (%2)) && ((((%3)[(%2) + 1] == '\0') && (dcmd_%1(playerid, ""))) || (((%3)[(%2) + 1] == ' ') && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1

public OnFilterScriptInit()
{
print("Pwnt admin filterscript by IamNotKoollll and cotton509");
return 1;
}

public OnFilterScriptExit()
{
return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
dcmd(register,8,cmdtext);
dcmd(login,5,cmdtext);
return false;
}

dcmd_register(playerid, params)
{
#pragma unused params
return 1;
}

dcmd_login(playerid, params)
{
#pragma unused params
return 1;
}


C:\Users\Mathew\Desktop\pwnt.pwn(27) : error 035: argument type mismatch (argument 2)
C:\Users\Mathew\Desktop\pwnt.pwn(2 : error 035: argument type mismatch (argument 2)
C:\Users\Mathew\Desktop\pwnt.pwn(32) : warning 203: symbol is never used: "playerid"
C:\Users\Mathew\Desktop\pwnt.pwn(3 : warning 203: symbol is never used: "playerid"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Errors.



Re: DCMD FAILS - Correlli - 22.04.2010

You're the one who fails. params parameter is a string, not an integer.


Re: DCMD FAILS - Calgon - 22.04.2010

You need to add '[]' to the end of "params" on each new dcmd command under OnPlayerCommandText.


Re: DCMD FAILS - IamNotKoolllll - 22.04.2010

Quote:
Originally Posted by Don Correlli
You're the one who fails. params parameter is a string, not an integer.
how do i fail sumone whos codded dcmd for 4 years now told me to use #pragma unused params and its never failed now help me or stop posting


Re: DCMD FAILS - IamNotKoolllll - 22.04.2010

Quote:
Originally Posted by FreddoX [BINMAN
]
You need to add '[]' to the end of "params" on each new dcmd command under OnPlayerCommandText.
THANK YOU finaly a propper awnswer ^_^


Re: DCMD FAILS - Calgon - 22.04.2010

Quote:
Originally Posted by IamNotKoolllll
Quote:
Originally Posted by Don Correlli
You're the one who fails. params parameter is a string, not an integer.
how do i fail sumone whos codded dcmd for 4 years now told me to use #pragma unused params and its never failed now help me or stop posting
You still fail, creating a thread called "DCMD FAILS" because of your lack of a brain.


Re: DCMD FAILS - IamNotKoolllll - 22.04.2010

Quote:
Originally Posted by FreddoX [BINMAN
]
Quote:
Originally Posted by IamNotKoolllll
Quote:
Originally Posted by Don Correlli
You're the one who fails. params parameter is a string, not an integer.
how do i fail sumone whos codded dcmd for 4 years now told me to use #pragma unused params and its never failed now help me or stop posting
You still fail, creating a thread called "DCMD FAILS" because of your lack of a brain.
i have a brain the thread is changed now u wana continue to troll? huh? AND ITS A SIMPLE MISTAKE I FORGOT [] SIMPLE MISTAKE


Re: DCMD FAILS - Calgon - 22.04.2010

Quote:
Originally Posted by IamNotKoolllll
Quote:
Originally Posted by FreddoX [BINMAN
]
Quote:
Originally Posted by IamNotKoolllll
Quote:
Originally Posted by Don Correlli
You're the one who fails. params parameter is a string, not an integer.
how do i fail sumone whos codded dcmd for 4 years now told me to use #pragma unused params and its never failed now help me or stop posting
You still fail, creating a thread called "DCMD FAILS" because of your lack of a brain.
i have a brain the thread is changed now u wana continue to troll? huh? AND ITS A SIMPLE MISTAKE I FORGOT [] SIMPLE MISTAKE
Calm down, this is a forum and not a wrestling ring - there's no need for capitals, you could have been more civilized and properly asked for help and named the thread "DCMD issue - help please" or something along those lines, instead you decided to attempt to criticize it because you've no clue what you're doing.


Re: DCMD WINS [SOLVED] - iLinx - 22.04.2010

Whoah, take it easy.


Re: DCMD WINS [SOLVED] - IamNotKoolllll - 22.04.2010

Quote:
Originally Posted by iLinx
Whoah, take it easy.
... D: i needed help and insulting not giving a awnser (the first guy) didnt help