06.02.2015, 19:10
Код:
C:\Users\Luiz\Documents\SAMP 0.3z Server\pawno\include\losgs.inc(1) : error 010: invalid function or declaration
E quando vou tentar compilar o GM, dб erro na include

Cуdigo da include: (Nгo modifiquei nada na include, й porque ela vem em TXT, eu simplesmente abri o TXT e o salvei como .inc pra funcionar.
Код:
/* native CreateLog(const file[]); native WriteLog(const file[], string[]); native RemoveLog(const file[]); native LogExists(const file[]); */ #define LogExists fexist stock CreateLog(const file[]) { if(LogExists(file ) ) { print("--------------------------------------------------------------------"); printf("Losgs: Vocк estб tentando criar um log jб existente (%s)", file); print("Losgs: Consulte o tуpico oficial para mais informaзхes."); print("Losgs: https://sampforum.blast.hk/showthread.php?tid=293534"); print("--------------------------------------------------------------------"); return 0; } new File: logFile = fopen(file, io_write); fclose(logFile); return 1; } stock WriteLog(const file[], string[], maxlength = sizeof(string)) { if(!LogExists(file)) CreateLog(file); new year, month, day, hour, minute, second, stringLog[600]; getdate(year, month, day); gettime(hour, minute, second); format(stringLog, maxlength + 27, "(%02d/%02d/%d)[%02d:%02d:%02d] %s\r\n", day, month, year, hour, minute, second, string); new File: logFile = fopen(file, io_append); fwrite(logFile, stringLog); fclose(logFile); return 1; } stock RemoveLog(const file[]) { if(!LogExists(file)) { print("--------------------------------------------------------------------"); printf("Losgs: Vocк estб tentando deletar um log que nгo existe (%s)", file); print("Losgs: Consulte o tуpico oficial para mais informaзхes."); print("Losgs: https://sampforum.blast.hk/showthread.php?tid=293534"); print("--------------------------------------------------------------------"); return 0; } fremove(file); return 1; }