2001-01-19 03:30:16 +00:00
|
|
|
/* Console */
|
|
|
|
|
|
|
|
#ifndef _CONSOLE_H_
|
|
|
|
#define _CONSOLE_H_ 1
|
|
|
|
|
2001-01-22 15:45:41 +00:00
|
|
|
#include "pstypes.h"
|
|
|
|
|
2001-01-19 03:30:16 +00:00
|
|
|
/* Priority levels */
|
|
|
|
#define CON_CRITICAL -2
|
|
|
|
#define CON_URGENT -1
|
|
|
|
#define CON_NORMAL 0
|
|
|
|
#define CON_VERBOSE 1
|
|
|
|
#define CON_DEBUG 2
|
|
|
|
|
|
|
|
int con_init(void);
|
2003-06-06 19:04:27 +00:00
|
|
|
void con_resize(void);
|
2001-01-19 03:30:16 +00:00
|
|
|
void con_printf(int level, char *fmt, ...);
|
|
|
|
|
2003-06-02 01:55:03 +00:00
|
|
|
void con_show(void);
|
2001-01-19 03:30:16 +00:00
|
|
|
void con_draw(void);
|
|
|
|
void con_update(void);
|
2003-06-06 19:04:27 +00:00
|
|
|
int con_events(int key);
|
2001-01-19 03:30:16 +00:00
|
|
|
|
|
|
|
/* CVar stuff */
|
|
|
|
typedef struct cvar_s
|
|
|
|
{
|
|
|
|
char *name;
|
|
|
|
char *string;
|
|
|
|
dboolean archive;
|
|
|
|
float value;
|
|
|
|
struct cvar_s *next;
|
|
|
|
} cvar_t;
|
|
|
|
|
|
|
|
extern cvar_t *cvar_vars;
|
|
|
|
|
|
|
|
/* Register a CVar with the name and string and optionally archive elements set */
|
|
|
|
void cvar_registervariable (cvar_t *cvar);
|
|
|
|
|
|
|
|
/* Equivalent to typing <var_name> <value> at the console */
|
|
|
|
void cvar_set(char *cvar_name, char *value);
|
|
|
|
|
|
|
|
/* Get a CVar's value */
|
|
|
|
float cvar(char *cvar_name);
|
|
|
|
|
|
|
|
/* Console CVars */
|
|
|
|
/* How discriminating we are about which messages are displayed */
|
2001-01-31 14:04:46 +00:00
|
|
|
extern cvar_t con_threshold;
|
2001-01-19 03:30:16 +00:00
|
|
|
|
|
|
|
#endif /* _CONSOLE_H_ */
|
|
|
|
|