Help with this command.
#1

pawn Код:
CMD:invite(playerid,params[])
{
    if(pInfo[playerid][pLeader] >= 1)
    {
        return SendClientMessage(playerid,-1,"You May not Use this command");
    }
    new ftext[50], pName[MAX_PLAYER_NAME],iName[MAX_PLAYER_NAME],id,string[128];
    if(sscanf(params,"u",id))
    {
        return SendClientMessage(playerid,-1,"USAGE:/invite [id/partofname]");
    }
    if(pInfo[playerid][pLeader] == 1)
    {
        ftext = "LSPD";
        SetPlayerSkin(id,288);
        pInfo[id][pMember] = pInfo[playerid][pLeader];
        pInfo[id][pRank] = 1;
    }
    else if(pInfo[playerid][pLeader] == 2)
    {
        ftext = "NCR";
        SetPlayerSkin(id,287);
        pInfo[id][pMember] = pInfo[playerid][pLeader];
        pInfo[id][pRank] = 1;
    }
    else
    {
    GetPlayerName(playerid,pName,sizeof(pName));
    GetPlayerName(id,iName,sizeof(iName));
    format(string,sizeof(string),"You Have been invited to %s by the Leader %s",ftext,pName);
    SendClientMessage(id,COLOR_BLUE,string);
    format(string,sizeof(string),"You have invited %s to Join %s",iName,ftext);
    SendClientMessage(playerid,COLOR_BLUE,string);
    }
    return 1;
}
I'm a leader of LSPD when i try to invite and budy its tall me You may not use this commad.
Reply


Messages In This Thread
Help with this command. - by Gangster-rocks - 20.07.2012, 11:03
Re: Help with this command. - by Infinity90 - 20.07.2012, 11:09
Re: Help with this command. - by Andi_Evandy - 20.07.2012, 11:23

Forum Jump:


Users browsing this thread: 1 Guest(s)