: error 035: argument type mismatch (argument 3)
#1

pawn Код:
CMD:changepassword(playerid, params[])
{
    new string[128], string1[32], password[32];
    if(sscanf(params, "s[32]", password)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /changepassword [new password]");
   
    format(string, sizeof(string), "You have changed your password to %s, effect starts from now.", password);
    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
    new INI:File = INI_Open(UserSavePath(playerid));
    INI_WriteInt(File, "Password", password);
    INI_Close(File);
    return 1;
}
Error line:
INI_WriteInt(File, "Password", password);

thank you, rep
Reply
#2

Try that,

INI_WriteInt(File, "Password", password));
Reply
#3

More errors now
Reply
#4

This is what you should use to save a string:
pawn Код:
INI_WriteString(File, "Password", password);
Reply
#5

rep'd
Reply
#6

pawn Код:
error 033: array must be indexed (variable "-unknown-")
Got this error when doing another like function

function:
pawn Код:
Job_ReturnID(jobid)
{

    new
        szName[32] = "0";

    switch(jobid) {
        case 1: szName = "1";
        case 2: szName = "2";
    }
    return szName;
}
Line of error: new jobs = Job_ReturnID(jobid);
Reply
#7

pawn Код:
new jobs[32];
jobs = Job_ReturnID(jobid);
Reply
#8

'error 017: undefined symbol "jobid"
line: jobs = Job_ReturnID(jobid);
Reply
#9

You'll need to paste the command or whatever it is that you're working with, so that I can see what you're trying to do.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)