25.12.2018, 02:13
Each of these callbacks are useless. Why would anyone ever need these? The user triggers these callbacks by calling functions so why would anyone need to use a callback? It just adds extra layers of convulsion.
You included it so why don't you use your own iterators? This leads to the next point where this helps big time.
No array validation checks.
If you are going to use an enum use it! Write out as many entries as possible and avoid directly referencing array indexes. Yes you can do this but it gets ugly real fast.
There is just so much substance lacking with this framework I don't know where to start.
Код:
forward OnJobCreate(jobID, Float:jPos_X, Float:jPos_Y, Float:jPos_Z); - CALLED AFTER CreateJob FUNCTION forward OnPlayerGetNewJob(playerid, jobID); CALLED AFTER SetPlayerJob FUNCTION forward OnPlayerRemoveFromJob(playerid, jobID); CALLED AFTER RemovePlayerFromJob FUNCTION
Код:
#include <YSI\y_iterate>
Код:
stock GetJobPayment(jobID) { return VAR__typeJob[VAR__Job[jobID][jobType]][JTYPpayment]; }
Код:
enum main_job { //Back-end jName[MAX_JOB_NAME], JobType:jobType, Float:jPosition[3], //Front-end jPickup }