Must be assigned to an array.
#1

pawn Код:
else if(dialogid == 4) {
        if(!response) {
            SendClientMessage(playerid, COLOR_RED, "You must register.");
            Kick(playerid);
        }
        format(string, sizeof(string), "Immigration Officer: Ah, you speak with an %s accent!", strpack(string2, inputtext));
        SendClientMessage(playerid, COLOR_WHITE, string);
        pInfo[playerid][Accent] = string2; //Line 351
        dini_IntSet(fileLoc, "Accent", string2); //Line 352
    }
Here's my error:
Quote:

C:\Users\James\Desktop\SAMP\gamemodes\roleplay.pwn (351) : error 006: must be assigned to an array
C:\Users\James\Desktop\SAMP\gamemodes\roleplay.pwn (352) : error 035: argument type mismatch (argument 3)

Reply
#2

Are you initializing pInfo[playerid][Accent] and string2 as an array?
Reply
#3

pawn Код:
enum playerData {
    Level,
    Experience,
    WS1,
    WS1Ammo,
    WS2,
    WS2Ammo,
    WS3,
    WS3Ammo,
    spawnX,
    spawnY,
    spawnZ,
    Registered,
    Age,
    Sex,
    Accent,
    Step
}
new pInfo[MAX_PLAYERS][playerData];
and
pawn Код:
new string2[128];
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)