accept commands - 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: accept commands (
/showthread.php?tid=295615)
accept commands -
DaRkAnGeL[NBK] - 06.11.2011
Hey,
I am currently scripting a new faction for my server SAnews using ZCMD i wanted to make the accept command.
So i did CMD:accept sanews(playerid,params[]) that didnt work. I then tryed CMD:accept_sanews(playerid,params[]) which didnt give errors like the last one. Would that work as a space? If not please tell me how
![Smiley](images/smilies/smile.png)
.
Errors:
Код:
C:\Users\Admin\Desktop\SAMP\Midnight Drifts\gamemodes\LSRP.pwn(185) : error 001: expected token: "(", but found "-identifier-"
C:\Users\Admin\Desktop\SAMP\Midnight Drifts\gamemodes\LSRP.pwn(185) : error 001: expected token: ";", but found "("
C:\Users\Admin\Desktop\SAMP\Midnight Drifts\gamemodes\LSRP.pwn(187) : error 010: invalid function or declaration
C:\Users\Admin\Desktop\SAMP\Midnight Drifts\gamemodes\LSRP.pwn(188) : error 010: invalid function or declaration
C:\Users\Admin\Desktop\SAMP\Midnight Drifts\gamemodes\LSRP.pwn(194) : error 010: invalid function or declaration
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
5 Errors.
Re: accept commands -
Kayaque - 07.11.2011
You need to use strcmp.
CMD:accept(playerid, input[])
if(strcmp(input, "sanews", false) == 0)
{
check if he has been invited here..
{
set the stats here
}
}
return 1;
}