Pawn.CMD problem - 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: Pawn.CMD problem (
/showthread.php?tid=617772)
Pawn.CMD problem -
Cr4nh - 26.09.2016
Hello, i have problem with plugin Pawn.CMD
https://sampforum.blast.hk/showthread.php?tid=608474
When install all and compile get this errors:
Код:
C:\Users\Antonio\Desktop\UNDERSTYLE ROLEPLAY - SAMP\pawno\include\Pawn.CMD.inc(56) : error 025: function heading differs from prototype
C:\Users\Antonio\Desktop\UNDERSTYLE ROLEPLAY - SAMP\pawno\include\Pawn.CMD.inc(60) : error 025: function heading differs from prototype
Pawn.CMD include:
http://pastebin.com/gPCVKCfs
56 line:
Код:
forward OnPlayerCommandReceived(playerid, cmd[], params[], flags);
60 line:
Код:
forward OnPlayerCommandPerformed(playerid, cmdtext[], success)
55-61 line:
Код:
#if defined OnPlayerCommandReceived
forward OnPlayerCommandReceived(playerid, cmd[], params[], flags);
#endif
#if defined OnPlayerCommandPerformed
forward OnPlayerCommandPerformed(playerid, cmdtext[], success)
#endif
Re: Pawn.CMD problem -
Konstantinos - 26.09.2016
Find these two callbacks in your script and change the parameters to those listed in the include file.
Re: Pawn.CMD problem -
Cr4nh - 26.09.2016
thanks
i fix , but result -1 is for old !succes, 0 is for succes ?
Re: Pawn.CMD problem -
Konstantinos - 26.09.2016
result will be -1 if the command doesn't exist. In ZCMD and earlier versions of Pawn.CMD there was
success parameter with value of 0 if the command didn't exist and 1 if it did.
Re: Pawn.CMD problem -
Crayder - 26.09.2016
Quote:
Originally Posted by Konstantinos
result will be -1 if the command doesn't exist. In ZCMD and earlier versions of Pawn.CMD there was success parameter with value of 0 if the command didn't exist and 1 if it did.
|
Just a note to add to that...
result is -1 when the command doesn't exist.
Otherwise
result is whatever you return in the command.