Formats and dini >.> - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Formats and dini >.> (
/showthread.php?tid=208809)
Formats and dini >.> -
Lorenc_ - 09.01.2011
Hey guys i was making some ban cmd that saves all data to a ban file although how the f cant this work.
pawn Код:
stock ShowBan(playerid)
{
new file[26], string[256];
format(file, sizeof(file), BAN_FILE_2, ReturnPlayerName(playerid));
format(string, 256, "You are banned from this server. If you've feel you have been wrongfully ban please reply at "#SERVER_WEBSITE"\n\n"COL_RED"BANNED BY: %s\nBANNED DATE: %s\nBANNED TIME: %s\nBANNED REASON: %s", dini_Get(file,"BANBY"), dini_Get(file,"BANDATE"), dini_Get(file,"BANTIME"), dini_Get(file,"BANREASON"));
ShowPlayerDialog(playerid, NOREPONSE, DIALOG_STYLE_MSGBOX, "Call of Duty: Blackops", string, "Ok", "");
Kick(playerid);
}
Its loading no values at all for some reason ?
Well its really suppose to read
Код:
IP=5.57.93.125
BANBY=Lorenc
BANDATE=09/January/2011
BANTIME=21/24/56
BANREASON=r
But it dosent. Anyone know why,
It says on my client You been ban by: (no person)
-Lorenc.
Re: Formats and dini >.> -
MadeMan - 09.01.2011
Show BAN_FILE_2 define.
Re: Formats and dini >.> -
Lorenc_ - 09.01.2011
pawn Код:
#define BAN_FILE_2 "COD/players/bans/%s.ini"
Re: Formats and dini >.> -
MadeMan - 09.01.2011
You should increase 'file' size.
pawn Код:
new file[64], string[256];
Re: Formats and dini >.> -
Lorenc_ - 09.01.2011
You are completely a hero, many, many thanks.