new defines for return values of the callbacks
There is CMD_SUCCESS and CMD_FAILURE which are expected to be used as return values in the command functions.
These definitions don't quite make sense for use in the OnPlayerCommandReceived callback. I was considering adding new defines specifically to serve the purpose of the return values in those callbacks because the existing defines are confusing (and returning numbers are bad as always).
My Proposal:
-
OnPlayerCommandReceived
CMD_IGNORE- tells the command processor to ignore the command, i.e: command won't be executed and won't be forwarded to other scripts as wellCMD_PROCESS- tells the command processor to go ahead and execute the command if it is in the current script or otherwise forward it to other scripts -
OnPlayerCommandPerformed
CMD_SUCCESSandCMD_FAILUREmake sort of sense for this callback. Hence, I believe dedicated new defines aren't needed for the return values of this callback.
Opinions:
Anyone can come up with their own proposal or offer suggestions/opinions on proposals.