Questions about stats.
#10

Quote:
Originally Posted by Devilxz97
Посмотреть сообщение
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/stats", cmdtext, true, 10) == 0)
    {
        new DIALOG_STATS;
        new str[256];
        new money;
        new name;
        new score;
        new weapon[32];
        new playerweapon;
        money = PlayerInfo[playerid][pMoney],
        name = PlayerInfo[playerid][pName],
        score = PlayerInfo[playerid][pScore],
        weapon = PlayerInfo[playerid][pWeapon];
        GetWeaponName(playerweapon, weapon, sizeof(weapon));
        format(str, sizeof(str), "Name:[ %s ]\nMoney: [ %d ]\nScore: [ %d ]\nWeapon: [ %s ]", name,money,score,weapon);
        ShowPlayerDialog(playerid, DIALOG_STATS, DIALOG_STYLE_MSGBOX , "PlayerStats", str, "Close", "");
        return 1;
    }
}
try this . .

How did you know he have that weapon enum or not?
And please stop posting random codes from your script.
There was not even need for string sized [256] in your heal command.
Reply


Messages In This Thread
Questions about stats. - by TaLhA XIV - 27.07.2012, 10:19
Re: Questions about stats. - by Misiur - 27.07.2012, 10:21
Re: Questions about stats. - by TaLhA XIV - 27.07.2012, 11:10
Re: Questions about stats. - by TaLhA XIV - 27.07.2012, 12:24
Re: Questions about stats. - by Misiur - 27.07.2012, 12:32
Re: Questions about stats. - by Devilxz97 - 27.07.2012, 13:49
Re: Questions about stats. - by TaLhA XIV - 27.07.2012, 15:10
Re: Questions about stats. - by Misiur - 27.07.2012, 15:41
Re: Questions about stats. - by iTzZh - 27.07.2012, 16:02
Re: Questions about stats. - by Littlehelper - 27.07.2012, 17:59

Forum Jump:


Users browsing this thread: 2 Guest(s)