format issues
#1

I have this:
pawn Код:
crime1 = PlayerInfo[targetid][pWanted1];
            crime2 = PlayerInfo[targetid][pWanted2];
            crime3 = PlayerInfo[targetid][pWanted3];
            crime4 = PlayerInfo[targetid][pWanted4];
            crime5 = PlayerInfo[targetid][pWanted5];
            crime6 = PlayerInfo[targetid][pWanted6];
            crimes = PlayerInfo[targetid][pCrimes];
            arrests = PlayerInfo[targetid][pArrested];
            format(string, sizeof(string), "______________________________[%s Crimes]_____________________________", RPNU(targetid));
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 1: {FFFFFF}%s", crime1);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 2: {FFFFFF}%s", crime2);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 3: {FFFFFF}%s", crime3);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 4: {FFFFFF}%s", crime4);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 5: {FFFFFF}%s", crime5);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crime 6: {FFFFFF}%s", crime6);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Crimes: {FFFFFF}%i", crimes);
            SendClientMessage(playerid, COLOR_ORANGE, string);
            format(string, sizeof(string), "Arrests: {FFFFFF}%i", arrests);
            SendClientMessage(playerid, COLOR_ORANGE, string);
But this is what it shows.
Quote:

[23:23:50] ______________________________[Henk Crimes]_____________________________

[23:23:50] Crime 1: {FFFFFF}t______________________________[Henk Crimes]_____________________________

[23:23:50] Crime 2: {FFFFFF}

[23:23:50] Crime 3: {FFFFFF}

[23:23:50] Crime 4: {FFFFFF}

[23:23:50] Crime 5: {FFFFFF}

[23:23:50] Crime 6: {FFFFFF}

[23:23:50] Crimes: {FFFFFF}1

[23:23:50] Arrests: {FFFFFF}0

It only shows the "t" and the top line agian.
And instead of the "t" there should be "test2" and without the ------[.. crimes] thing.
Reply
#2

Bump
Reply
#3

You are using string dude.. %s
and that crime12345 etc is defined as string? if not use there %d
Reply
#4

No its a string.
Crime123456 stands for the Crime what they did.
Reply
#5

Then the fail is that yours PlayerInfo[targetid][pWanted123456],i mean show me the enum
Reply
#6

This i have under pInfo
pawn Код:
pWanted1[64],
    pWanted2[64],
    pWanted3[64],
    pWanted4[64],
    pWanted5[64],
    pWanted6[64],
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)