On command process for Y_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: On command process for Y_Commands? (
/showthread.php?tid=622635)
On command process for Y_Commands? -
TwinkiDaBoss - 25.11.2016
I am now going thru the Y Commands trying to find OnCommandProcess, or OnCommandAttempt or anything related to that, anyone got anything useful? Or should I just make a callback for that myself?
EDIT: I know about OnPlayerCommandPerformed(playerid,cmdtext[],success) but I am looking for something that calls before the command was executed and not after it
EDIT 2:
So far I found
// Forwards for optional command callbacks.
Quote:
forward e_COMMAND_ERRORS:OnPlayerCommandReceived(playerid, cmdtext[], e_COMMAND_ERRORSuccess);
forward e_COMMAND_ERRORS:OnPlayerCommandPerformed(playerid , cmdtext[], e_COMMAND_ERRORSuccess);
|
Altho hmm, seems that it goes as "headers different from prototype" when I use it as
Quote:
public OnPlayerCommandReceived(playerid, cmdtext[],success)
|
Re: On command process for Y_Commands? -
SickAttack - 25.11.2016
OnPlayerCommandReceived is called before a command is executed.
Re: On command process for Y_Commands? -
TwinkiDaBoss - 25.11.2016
Yeah I know, I am just looking for an alternative to it but seems that besides those are there isnt any pre-command callbacks