alog error
#9

hmm, found this already in my script, should i replace it with the new u game me?
Код:
aLog(file[], msg[])
{
	new fName[256], entry[256], File: hFile;
	gettime(Hour, Minute, Second);
	getdate(Year, Month, Day);

	format(fName, sizeof(fName), "/VirtualScriptingRP/Logs/%s", file);
	if(!fexist(fName))
	{
		dini_Create(fName);
		format(entry, sizeof(entry), "[%d/%d] [%d:%d] File created!\r\n", Day, Month, Hour, Minute);
		hFile = fopen(fName, io_append);
		fwrite(hFile, entry);
		format(entry, sizeof(entry), "[%d/%d] [%d:%d] %s\r\n", Day, Month, Hour, Minute, msg);
		fwrite(hFile, entry);
		fclose(hFile);
	}
	else
	{
		format(entry, sizeof(entry), "[%d/%d] [%d:%d] %s\r\n", Day, Month, Hour, Minute, msg);
		hFile = fopen(fName, io_append);
		fwrite(hFile, entry);
		fclose(hFile);
	}
}
Reply


Messages In This Thread
alog error - by thuron - 12.02.2009, 06:53
Re: alog error - by [RP]Rav - 12.02.2009, 07:03
Re: alog error - by thuron - 12.02.2009, 11:06
Re: alog error - by [RP]Rav - 12.02.2009, 11:10
Re: alog error - by thuron - 12.02.2009, 11:12
Re: alog error - by [RP]Rav - 12.02.2009, 11:13
Re: alog error - by thuron - 12.02.2009, 11:13
Re: alog error - by ICECOLDKILLAK8 - 12.02.2009, 11:15
Re: alog error - by thuron - 12.02.2009, 11:18
Re: alog error - by ICECOLDKILLAK8 - 12.02.2009, 11:27

Forum Jump:


Users browsing this thread: 1 Guest(s)