if(strcmp(cmdtext,"/help", true) == 0)
{
SendClientMessage(playerid, COLOR,"Welcome to my Server Help - Usage: /Help [Section]");
SendClientMessage(playerid, COLOR,"Sections: General, Chats, Faction...");
return 1;
}
if(strcmp(cmdtext,"/help General", true) == 0)
{
SendClientMessage(playerid, COLOR,"Something here");
return 1;
}
if(strcmp(cmd, "/help", true) == 0)
{
if(IsPlayerConnected(playerid))
{
SendClientMessage(playerid, COLOR_GRAD1,":: ACCOUNT :: /rules /stats /account /rules /information");
SendClientMessage(playerid, COLOR_GRAD1,":: GENERAL :: /pay /charity /time /buy /switchkey /id /drink /clothes /restartspawn");
SendClientMessage(playerid, COLOR_GRAD2,":: GENERAL :: /resetupgrades(50k) /buygun /lock /licenses /showlicenses(/sl) /report /asay /animlist /stopanim /fuel /use");
SendClientMessage(playerid, COLOR_GRAD2,":: GENERAL :: /report /cancel /accept /eject /usedrugs /contract /fill /admins /gps /chatmode /fightstyle /(de)attachweapon");
SendClientMessage(playerid, COLOR_GRAD3,":: GENERAL :: /windows /coin /trunk (/inv)entory /knock /knockout /give /open /sid /smoke /(sur)render /cophelp /selectspawn");
SendClientMessage(playerid, COLOR_GRAD3,":: CHAT :: (/o)oc /me /(ad)vertise (/carw)hisper (/s)hout /(w)hisper (/b) /(l)ocal (/f)action /me /do /togfam /togpm /togphone");
SendClientMessage(playerid, COLOR_GRAD4,":: BANK :: /balance /withdraw /deposit /atm");
if(PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 1)
{
SendClientMessage(playerid, COLOR_YELLOW2, ":: LCN :: (/r)adio /news /papers");
}
if(PlayerInfo[playerid][pJob] == 1) {
SendClientMessage(playerid,COLOR_YELLOW2,":: JOB - Detective:: /find"); }
else if(PlayerInfo[playerid][pJob] == 2) {
SendClientMessage(playerid,COLOR_YELLOW2,":: JOB - Lawyer :: /free"); }
else if(PlayerInfo[playerid][pJob] == 3) {
SendClientMessage(playerid,COLOR_YELLOW2,":: JOB - Taxi company :: /tduty /jopen"); }
if (PlayerInfo[playerid][pAdmin] >= 1)
{
SendClientMessage(playerid, COLOR_YELLOW, ":: ADMIN :: /admin or // (/ah)elp");
}
SendClientMessage(playerid, COLOR_GRAD6,":: OTHER :: /cellphonehelp /househelp /notehelp /vehiclehelp /renthelp /businesshelp /leaderhelp /fishhelp /cookhelp /irchelp /derbyhelp");
}
return 1;
}
|
so you want somthing like
/help general /help faction /help donator ect. ?? |
if(strcmp(cmd, "/help", true) == 0) // by Cuervo
{
if(IsPlayerConnected(playerid))
{
new x_nr[24];
x_nr = strtok(cmdtext, idx);
if(!strlen(x_nr))
{
SendClientMessage(playerid, COLOR_GREY, "COMANDS: commands.. [");
SendClientMessage(playerid, COLOR_GREY, "COMANDS: /help admin /help gm /help leader");
return 1;
}
if(strcmp(x_nr,"admin",true) == 0)
{
SendClientMessage(playerid, COLOR_GREY, "COMANDS: commands");
}
else if(strcmp(x_nr,"gm",true) == 0)
{
SendClientMessage(playerid, COLOR_GREY, "COMANDS: commands");
}
else if(strcmp(x_nr,"leader",true) == 0)
{
SendClientMessage(playerid, COLOR_GREY, "COMANDS: commands");
}
else return SendClientMessage(playerid, COLOR_GREY,"* Unknown help!");
}
return 1;
}