SA-MP Forums Archive
Help error 035: - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help error 035: (/showthread.php?tid=454951)



Help error 035: - JusstinRoller - 31.07.2013

i have this error:
PHP код:
C:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(79) : error 035argument type mismatch (argument 1)
C:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(80) : error 035argument type mismatch (argument 1)
C:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(81) : error 035argument type mismatch (argument 1
But i don't know how to fix

here is line 79,80,81:
PHP код:
        format(file,sizeof(file),"Houses/%i.ini",i);
        
INI_Open(file);
        
INI_WriteInt(file,"Owner",1);// Line 79 here
        
INI_WriteString(file,"Owner",pName);// line 80 here
        
INI_Close(file);//line 81 here 



Re: Help error 035: - Chenko - 31.07.2013

It's showing a tag mismatch warning because it's looking for a INI tag but it's getting a string. You need to do it like this:

Код:
new INI:file2 = INI_Open(file);
INI_WriteInt(file2, "Owner", 1);
etc...
INI_Close(file2);



Re: Help error 035: - JusstinRoller - 31.07.2013

Thanks but i fixed and have this error
PHP код:
C:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(80) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(81) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(82) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(83) : warning 213tag mismatch 
4 line
PHP код:
        new file INI_Open(HousePath);
        
INI_WriteInt(file,"Owner",1);
        
INI_WriteString(file,"Owner",pName);
        
INI_Close(file); 



Re: Help error 035: - JusstinRoller - 31.07.2013

help


Re: Help error 035: - JusstinRoller - 31.07.2013

help


Re: Help error 035: - dEcooR - 31.07.2013

I hope that works

Код:
stock HousePath(houseid)
{
       new house[64];
       format(house,64,"Houses/house%d.ini",houseid);
       return house;
}

new INI:File = INI_Open(HousePath(houseid));
INI_WriteInt(File,"Owner",1);
INI_WriteString(File,"Owner",pName);
INI_Close(File);



Re: Help error 035: - Chenko - 31.07.2013

Quote:
Originally Posted by JusstinRoller
Посмотреть сообщение
Thanks but i fixed and have this error
PHP код:
C:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(80) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(81) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(82) : warning 213tag mismatch
C
:\Users\Admin\Desktop\samp03x_svr_R1-2_win32\filterscripts\test_sublime.pwn(83) : warning 213tag mismatch 
4 line
PHP код:
        new file INI_Open(HousePath);
        
INI_WriteInt(file,"Owner",1);
        
INI_WriteString(file,"Owner",pName);
        
INI_Close(file); 
You are missing the INI: before file.

Код:
new file = INI_Open(HousePath);
Should be:

Код:
new INI:file = INI_Open(HousePath);