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



Warning... - RedSmokeR - 21.10.2018

Hi Guyz,I am Getting a warning "
PHP Code:
warning 235: public function lacks forward declaration (symbol "OnPlayerCommandPerformed"
Here is my Code:
Define : #define ERROR_MSG "Unknown Command! Type /cmds For Available Commands."
Line :
PHP Code:
public OnPlayerCommandPerformed(playeridcmdtext[], success)
{
    if(!
success)
    return 
SendClientMessage(playeridCOLOR_ERROR""ERROR_MSG"");
    return 
1;




Re: Warning... - Calisthenics - 21.10.2018

Only certain command processors provide this callback, what do you use for commands?


Re: Warning... - RedSmokeR - 21.10.2018

Quote:
Originally Posted by Calisthenics
View Post
Only certain command processors provide this callback, what do you use for commands?
I am just using that if player perform any unknown command,The Message appears,The "ERROR_MSG"


Re: Warning... - UFF - 21.10.2018

That callback is used by zcmd. Have you included zcmd?|

pawn Code:
#include zcmd



Re: Warning... - RedSmokeR - 21.10.2018

Quote:
Originally Posted by UFF
View Post
That callback is used by zcmd. Have you included zcmd?|

pawn Code:
#include zcmd
Thanks Dude,I forgot to write...