1 Error In 1 Line
#1

Hi,
I Get It Error From That
pawn Код:
INI_WriteInt(file,"AdminLevel",PInfo[playerid][Adminlevel]);
And I Don't See Any Thing Wrong With That

Код:
error 035: argument type mismatch (argument 1)
Thanks
Reply
#2

Try putting a capital F for File. Happened to me before and that fixed it. If not show us more code please or previous lines or more.
Reply
#3

It Will Say Undefine Symbol File
Reply
#4

Hmm weird. Could you possibly post the whole bit of your saving please?
Reply
#5

make sure you have
pawn Код:
new INI:file;
above that.
Reply
#6

Now I Got That
Код:
error 035: argument type mismatch (argument 1)
2 Times
Reply
#7

Ex:
pawn Код:
new file[32],pName[MAX_PLAYER_NAME];
GetPlayerName(playerid,pName, MAX_PLAYER_NAME);

format(file, sizeof file, "%s.ini",pName);

new INI:ini = INI_Open(file);
Reply
#8

Symbol INI Is Never Used + error 035: argument type mismatch (argument 1)
Reply
#9

pawn Код:
new file[32],pName[MAX_PLAYER_NAME];
GetPlayerName(playerid,pName, MAX_PLAYER_NAME);

format(file, sizeof file, "%s.ini",pName);

new INI:ini = INI_Open(file);
INI_WriteInt(ini,"AdminLevel",PInfo[playerid][Adminlevel]); // Usage
Reply
#10

No Error But When I Type /setadmin Thats Happen
Код:
[05:18:32] *** YSI Error: INI_Open could not find or create file 
[05:18:34] *** YSI Error: INI_Open could not find or create file 
[05:18:38] *** YSI Error: INI_Open could not find or create file 
[05:18:41] *** YSI Error: INI_Open could not find or create file
Here Is My SetAdmin Cmd
pawn Код:
YCMD:setadmin(playerid, params[], help)
            {
            new level,id,n[MAX_PLAYER_NAME];
            new string[50];
            new on[MAX_PLAYER_NAME];
            new file[32],pName[MAX_PLAYER_NAME];
            new INI:ini = INI_Open(file);
            GetPlayerName(id,n,MAX_PLAYER_NAME);
            GetPlayerName(id,on,sizeof(on));
            format(file,sizeof(file),"MAdmin/Players/%s.txt",n);
            if(PInfo[playerid][Adminlevel] < 6) return SendClientMessage(playerid,ORANGE,"You're Not Rcon Admin!");
            if(sscanf(params,"ud",id,level)) return SendClientMessage(playerid,RED,"USAGE:/SetLevel [Playerid] [Level]");
            if(!IsPlayerConnected(id))return SendClientMessage(playerid,GREY,"You have entered an incorrect ID");
            PInfo[id][Adminlevel] = level;
            format(string,sizeof(string),"You have set %s's level to %d",on,level);
            SendClientMessage(playerid,LIGHTBLUE,string);
            format(string,sizeof(string),"Player %s Is Now Admin Level %d",on,level);
            SendClientMessageToAll(GREEN,string);
            GetPlayerName(playerid,pName, MAX_PLAYER_NAME);
            format(file, sizeof file, "Players/%s.ini",pName);
            INI_WriteInt(ini,"AdminLevel",PInfo[playerid][Adminlevel]);
            return 1;
    }
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)