09.02.2017, 14:41
I write it in a file, don't see why I should save it in a mysql table.
Use KickLog(string); under a format, example.
PHP код:
function KickLog(string[])
{
new
entry[ 128 ],
year,
month,
day,
hour,
minute,
second
;
getdate(year, month, day);
gettime(hour, minute, second);
format(entry, sizeof(entry), "%s | (%d-%d-%d) (%d:%d:%d)\n",string, day, month, year, hour, minute, second);
new File:hFile;
hFile = fopen("Basic/logs/KickLog.log", io_append);
fwrite(hFile, entry);
fclose(hFile);
}
PHP код:
format(string, sizeof(string), "x has kicked y", ...);
SendClientMessage(playerid, -1, string);
KickLog(string);

