lspd members with dialogs
#8

pawn Код:
new string[512]
new string2[512]
new string3[512]
//===================
new pdmembes = 0;
for(new i=0;i<MAX_PLAYERS;i++)
{
    if(PlayerIsACop[i]) // insert your own check here
    {
        pdmembs += 1;
        new pname[MAX_PLAYER_NAME];
        GetPlayerName(i, pname, sizeof(pname));
        if(pdmembes < 21)
        {
             format(string, 512, "%s%s\n", string, pname);
        }
        if(pdmembes < 41 && pdmembers > 20)
        {
             format(string2, 512, "%s%s\n", string2, pname);
        }
        if(pdmembes < 61 && pdmembers > 40)
        {
             format(string3, 512, "%s%s\n", string3, pname);
        }
    }
}

ShowPlayerDialog(playerid, 5, DIALOG_STYLE_MSGBOX, "Police officers online", string, "Forward", "Close");
You would have to make these three string variables global, and it would work only for up to 60 pd members. This is only for those online. I haven't tested it but it should work.
Reply


Messages In This Thread
lspd members with dialogs - by 'Pawno. - 26.06.2012, 21:39
Re: lspd members with dialogs - by Grand_Micha - 26.06.2012, 21:44
Re: lspd members with dialogs - by 'Pawno. - 26.06.2012, 21:52
Re: lspd members with dialogs - by Grand_Micha - 26.06.2012, 21:55
Re: lspd members with dialogs - by 'Pawno. - 26.06.2012, 21:59
Re: lspd members with dialogs - by Makaveli93 - 26.06.2012, 22:01
Re: lspd members with dialogs - by 'Pawno. - 26.06.2012, 22:13
Re: lspd members with dialogs - by Makaveli93 - 26.06.2012, 22:18
Re: lspd members with dialogs - by Jonny5 - 27.06.2012, 00:41
Re: lspd members with dialogs - by Makaveli93 - 27.06.2012, 01:00

Forum Jump:


Users browsing this thread: 2 Guest(s)