[debug] AMX backtrace: [22:13:01] [debug] #0 native CallLocalFunction () [00472260] from samp-server.exe [22:13:01] [debug] #1 0000129c in public OnPlayerCommandText () from sfrp.amx [22:13:01] [debug] System backtrace: [22:13:01] [debug] #0 004010b6 in ?? () from C:\SAMP SERVER\samp-server.exe [22:13:01] [debug] #1 74283322 in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [22:13:01] [debug] #2 74285766 in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [22:13:01] [debug] #3 7427beba in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [22:13:01] [debug] #4 7428334e in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [22:13:01] [debug] #5 0046cfe0 in ?? () from C:\SAMP SERVER\samp-server.exe [22:13:01] [debug] #6 0048b4d4 in ?? () from C:\SAMP SERVER\samp-server.exe [22:13:01] [debug] #7 7708e38c in RtlInitUnicodeString () from C:\Windows\SysWOW64\ntdll.dll [22:13:01] [debug] #8 7708e0f2 in RtlAllocateHeap () from C:\Windows\SysWOW64\ntdll.dll [22:13:01] [debug] #9 0045615c in ?? () from C:\SAMP SERVER\samp-server.exe
[12:33:13] [join] Jeff_Jackson has joined the server (17:108.62.214.247) [12:33:13] [debug] Server crashed while executing sfrp.amx [12:33:13] [debug] AMX backtrace: [12:33:13] [debug] #0 native CallLocalFunction () [00472260] from samp-server.exe [12:33:13] [debug] #1 0000129c in public OnPlayerCommandText () from sfrp.amx [12:33:13] [debug] System backtrace: [12:33:13] [debug] #0 004010b6 in ?? () from C:\SAMP SERVER\samp-server.exe [12:33:13] [debug] #1 73863322 in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [12:33:13] [debug] #2 73865766 in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [12:33:13] [debug] #3 7385beba in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [12:33:13] [debug] #4 7386334e in Load () from C:\SAMP SERVER\plugins\crashdetect.DLL [12:33:13] [debug] #5 0046cfe0 in ?? () from C:\SAMP SERVER\samp-server.exe [12:33:13] [debug] #6 0048b4d4 in ?? () from C:\SAMP SERVER\samp-server.exe [12:33:13] [debug] #7 7708e38c in RtlInitUnicodeString () from C:\Windows\SysWOW64\ntdll.dll [12:33:13] [debug] #8 7708e0f2 in RtlAllocateHeap () from C:\Windows\SysWOW64\ntdll.dll [12:33:13] [debug] #9 0045615c in ?? () from C:\SAMP SERVER\samp-server.exe |
public OnPlayerCommandPerformed( playerid, cmdtext[], success )
{
if( !success )
return ShowErrorMessage( playerid, "Unknown command, type /help or /helpme." );
else
{
if( strcmp( cmdtext, "/me", true ) != 0 || strcmp( cmdtext, "/do", true ) != 0)
CommandTime[playerid] = 0;
else if( strcmp( cmdtext, "/ban", true ) == 0)
CommandTime[playerid] = 7;
else CommandTime[playerid] = 1;
UncheckedPays[playerid] = 0;
format( szString, 128, "%s typed \"%s\"", GetPName( playerid ), cmdtext );
Log( szString, LOGTYPE_CMD );
}
return 1;
}
public OnPlayerCommandReceived( playerid, cmdtext[] )
{
if( PlayerInfo[playerid][LoggedIn] == 0) return 1;
if( CommandTime[playerid] != 0) {
format( szString, 128, "There are %d seconds left before you can perform another command.", CommandTime[playerid] );
ShowErrorMessage( playerid, szString );
return 0;
}
return 1;
}
stock Log( logString[], logType )
{
new logPath[128], fileEntry[128];
switch( logType ) {
case LOGTYPE_DEATH: logPath = DeathLogPath;
case LOGTYPE_BAN: logPath = BanLogPath;
case LOGTYPE_KICK: logPath = KickLogPath;
case LOGTYPE_AJAIL: logPath = AdminJailLogPath;
case LOGTYPE_CMD: logPath = UserCommandLogPath;
case LOGTYPE_ADMCMD: logPath = AdmCommandLogPath;
case LOGTYPE_PM: logPath = PMLogPath;
case LOGTYPE_PAY: logPath = PayLogPath;
case LOGTYPE_PURCHASE: logPath = PurchasesLogPath;
case LOGTYPE_ICCHAT: logPath = ICChatLogPath;
case LOGTYPE_OOCCHAT: logPath = OOCChatLogPath;
case LOGTYPE_ACTIONS: logPath = ActionLogPath;
case LOGTYPE_WEAPONRY: logPath = WeaponryLogPath;
}
new day, month, year;
new timesec, timemin, timehour;
getdate( year, month, day );
gettime( timehour, timemin, timesec );
format( fileEntry, 128, "[%d/%d/%d] [%d:%d:%d] %s\r\n", day, month, year, timehour, timemin, timesec, logString );
new File: logFile;
logFile = fopen( logPath, io_append );
fwrite( logFile, fileEntry );
fclose( logFile );
return 1;
}