1 /*
2 Copyright (C) 2004 VVD (vvd0@sorceforge.net).
3 
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public License
6 as published by the Free Software Foundation; either version 2
7 of the License, or (at your option) any later version.
8 
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12 
13 See the GNU General Public License for more details.
14 
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
18 
19 */
20 
21 #ifndef __LOG_H__
22 #define __LOG_H__
23 
24 enum {	MIN_LOG = 0, CONSOLE_LOG = 0, ERROR_LOG,  RCON_LOG,
25 		TELNET_LOG,  FRAG_LOG,        PLAYER_LOG, MOD_FRAG_LOG, MAX_LOG};
26 
27 typedef struct log_s {
28 	FILE		*sv_logfile;
29 	char		*command;
30 	char		*file_name;
31 	char		*message_off;
32 	char		*message_on;
33 	xcommand_t	function;
34 	int			log_level;
35 } log_t;
36 
37 extern	log_t	logs[MAX_LOG];
38 extern	cvar_t	frag_log_type;
39 extern	cvar_t	telnet_log_level;
40 
41 //bliP: logging
42 void	SV_Logfile (int sv_log, qbool newlog);
43 void	SV_LogPlayer(client_t *cl, char *msg, int level);
44 //<-
45 void	SV_Write_Log(int sv_log, int level, char *msg);
46 
47 #endif /* !__LOG_H__ */
48