Crazy rank system.
#4

That is because you didn't set the killzstats rank checks properly. Here is the correct one in accordance to the original one i gave you:
pawn Код:
if(strcmp(cmd, "/rankinfo", true) == 0)
    {
        new string1[48],string2[48],string3[48],string4[128],mstring[264];
        if(killzstats[playerid] <= 0)
        {
            format(string1, sizeof string1, "Rank: Private");
            format(string2, sizeof string2, "Kills: %d",killzstats);
            format(string3, sizeof string3, "Kills needed: 20 For next rank: Soldier");
            format(string4, sizeof string4, "Vehicles: Patriot, Barracks, Sanchez, Rustler.");
            format(mstring, sizeof mstring, "%s\n%s\n%s\n%s", string1,string2,string3,string4);
        }
        else if(killzstats[playerid] >= 1 && killzstats[playerid] <= 19) // 1-19
        {
            format(string1, sizeof string1, "Rank: Soldier");
            format(string2, sizeof string2, "Kills: %d",killzstats);
            format(string3, sizeof string3, "Kills needed: 50 For next rank: Sergeant");
            format(string4, sizeof string4, "Vehicles: Patriot,Barracks,Sanchez,Rustler,\nSeasparrow.");
            format(mstring, sizeof mstring, "%s\n%s\n%s\n%s", string1,string2,string3,string4);
        }
        else if(killzstats[playerid] > 20 && killzstats[playerid] <= 49) //20-49
        {
            format(string1, sizeof string1, "Rank: Sergeant");
            format(string2, sizeof string2, "Kills: %d",killzstats);
            format(string3, sizeof string3, "Kills needed: 100 For next rank: General");
            format(string4, sizeof string4, "Vehicles: Patriot, Barracks, Sanchez, Rustler,\nSeasparrow, Rhino, Hydra.");
            format(mstring, sizeof mstring, "%s\n%s\n%s\n%s", string1,string2,string3,string4);
        }
        else if(killzstats[playerid] >= 50) //50+
        {
            format(string1, sizeof string1, "Rank: General");
            format(string2, sizeof string2, "Kills: %d",killzstats);
            format(string3, sizeof string3, "Kills needed: - For next rank: -");
            format(string4, sizeof string4, "Vehicles: Patriot, Barracks, Sanchez, Rustler,\nSeasparrow, Rhino, Hydra, Hunter");
            format(mstring, sizeof mstring, "%s\n%s\n%s\n%s", string1,string2,string3,string4);
        }
        ShowPlayerDialog(playerid,911,DIALOG_STYLE_MSGBOX,"Rank info",mstring,"Okay","Cancel");
        return 1;
    }
For your reference, the Ranks are:
Код:
0 or less: Rank: Private
1-19: Rank: Soldier
20- 49:Rank: Sergeant
50+: Rank: General
Note: I edited my first post - I realised a little error. Please update.
Reply


Messages In This Thread
Crazy rank system. - by Striker_Moe - 08.11.2009, 13:33
Re: Crazy rank system. - by member - 08.11.2009, 14:02
Re: Crazy rank system. - by Striker_Moe - 08.11.2009, 14:14
Re: Crazy rank system. - by member - 08.11.2009, 14:24
Re: Crazy rank system. - by Striker_Moe - 08.11.2009, 14:29
Re: Crazy rank system. - by Striker_Moe - 08.11.2009, 14:39
Re: Crazy rank system. - by member - 08.11.2009, 14:42
Re: Crazy rank system. - by Striker_Moe - 08.11.2009, 14:49
Re: Crazy rank system. - by member - 08.11.2009, 14:52

Forum Jump:


Users browsing this thread: 1 Guest(s)