Question.
#6

pawn Код:
stock SaveHappening(filename[],text[])
{
    new File:Saving;
    new filepath[256];
    new string[256];
    new year,month,day;
    new hour,minute,second;

    getdate(year,month,day);
    gettime(hour,minute,second);
    format(filepath,sizeof(filepath),"Logs/%s.txt",filename);
    Saving = fopen(filepath,io_append);
    format(string,sizeof(string),"[%02d/%02d/| %02d:%02d] %s\r\n",day,month,hour,minute,text);
    fwrite(Saving,string);
    fclose(Saving);
    return 1;
}
To use,
pawn Код:
SaveHappening(banlog, str);
for example.
Reply


Messages In This Thread
Question. - by Face9000 - 20.12.2010, 17:04
Re: Question. - by blackwave - 20.12.2010, 17:12
Re: Question. - by Face9000 - 20.12.2010, 17:13
Re: Question. - by blackwave - 20.12.2010, 17:15
Re: Question. - by Face9000 - 20.12.2010, 17:18
Re: Question. - by Seven. - 20.12.2010, 17:19
Re: Question. - by Face9000 - 20.12.2010, 17:20
Re: Question. - by Face9000 - 20.12.2010, 17:38

Forum Jump:


Users browsing this thread: 1 Guest(s)