SA-MP Forums Archive
Y_ini Help - 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: Y_ini Help (/showthread.php?tid=449140)



Y_ini Help - TranquiliZed - 07.07.2013

How can you delete a file in Y_ini. I am using it so when the get kicked from my RP test(if they fail) but it currently saves there player file. I want it so when they get kicked it deletes there account. Please help


Re: Y_ini Help - park4bmx - 07.07.2013

https://sampwiki.blast.hk/wiki/Fremove


Re: Y_ini Help - TranquiliZed - 07.07.2013

Ok using that function How would do a path. Would this work

pawn Код:
fremove("Users\%s.ini", GetPlayerName(playerid));

//OR

fremove("Users\%s.ini"), GetPlayerName(playerid);



Re: Y_ini Help - TranquiliZed - 07.07.2013

Bump? Can someone help me...


Re: Y_ini Help - park4bmx - 07.07.2013

pawn Код:
new file[40];format(file,sizeof file,"Users\%s.ini", GetPlayerName(playerid));
fremove(file);



Re: Y_ini Help - TranquiliZed - 08.07.2013

Quote:
Originally Posted by park4bmx
Посмотреть сообщение
pawn Код:
new file[40];format(file,sizeof file,"Users\%s.ini", GetPlayerName(playerid));
fremove(file);
pawn Код:
hrp.pwn(2260) : warning 202: number of arguments does not match definition
hrp.pwn(2260) : warning 202: number of arguments does not match definition
hrp.pwn(2267) : warning 202: number of arguments does not match definition
hrp.pwn(2267) : warning 202: number of arguments does not match definition
hrp.pwn(2288) : warning 202: number of arguments does not match definition
hrp.pwn(2288) : warning 202: number of arguments does not match definition
hrp.pwn(2299) : warning 202: number of arguments does not match definition
hrp.pwn(2299) : warning 202: number of arguments does not match definition
hrp.pwn(2316) : warning 202: number of arguments does not match definition
hrp.pwn(2316) : warning 202: number of arguments does not match definition
hrp.pwn(2323) : warning 202: number of arguments does not match definition
hrp.pwn(2323) : warning 202: number of arguments does not match definition
hrp.pwn(2348) : warning 202: number of arguments does not match definition
hrp.pwn(2348) : warning 202: number of arguments does not match definition
hrp.pwn(2355) : warning 202: number of arguments does not match definition
hrp.pwn(2355) : warning 202: number of arguments does not match definition



Re: Y_ini Help - Stephano - 08.07.2013

pawn Код:
new file[40];format(file, sizeof(file),"Users\%s.ini", GetPlayerName(playerid));
fremove(file);



Re: Y_ini Help - TranquiliZed - 08.07.2013

Quote:
Originally Posted by Stephano
Посмотреть сообщение
pawn Код:
new file[40];format(file, sizeof(file),"Users\%s.ini", GetPlayerName(playerid));
fremove(file);
I get warning.... How do I fix it.


Re: Y_ini Help - Stephano - 08.07.2013

Well, if you still get the warnings, then you could try using "/" instead of "\". I doubt it will actually fix it.

On my script that I'm working on, I have it as this:

pawn Код:
new string[128], name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string, sizeof(string), "Accounts/%s.ini", name);
fremove(string);