Crossfire Server, Trunk  R20513
Data Structures | Macros | Typedefs | Variables
timers.h File Reference

Variables for the custom timers. More...

#include <global.h>
#include <object.h>
#include <time.h>
Include dependency graph for timers.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  _cftimer
 One timer. More...
 

Macros

#define MAX_TIMERS   1000
 Maximum number of timers. More...
 
#define TIMER_ERR_ID   -1
 Invalid timer id. More...
 
#define TIMER_ERR_MODE   -3
 Invalid timer mode. More...
 
#define TIMER_ERR_NONE   0
 No error. More...
 
#define TIMER_ERR_OBJ   -2
 NULL object, or no EVENT_TIMER handler. More...
 
#define TIMER_MODE_CYCLES   2
 Timer is in server cycles. More...
 
#define TIMER_MODE_DEAD   0
 Used to mark a timer as unused in the list. More...
 
#define TIMER_MODE_SECONDS   1
 Timer is in seconds. More...
 

Typedefs

typedef struct _cftimer cftimer
 One timer. More...
 

Variables

cftimer timers_table [MAX_TIMERS]
 The actual timers. More...
 

Detailed Description

Variables for the custom timers.

See Custom timers.

Definition in file timers.h.

Macro Definition Documentation

#define MAX_TIMERS   1000

Maximum number of timers.

Definition at line 61 of file timers.h.

Referenced by cftimer_create(), cftimer_destroy(), cftimer_find_free_id(), cftimer_init(), and cftimer_process_timers().

#define TIMER_ERR_ID   -1

Invalid timer id.

Definition at line 67 of file timers.h.

Referenced by cfapi_timer_create(), cftimer_create(), cftimer_destroy(), and cftimer_find_free_id().

#define TIMER_ERR_MODE   -3

Invalid timer mode.

Definition at line 69 of file timers.h.

Referenced by cftimer_create().

#define TIMER_ERR_NONE   0

No error.

Definition at line 66 of file timers.h.

Referenced by cfapi_timer_create(), cftimer_create(), and cftimer_destroy().

#define TIMER_ERR_OBJ   -2

NULL object, or no EVENT_TIMER handler.

Definition at line 68 of file timers.h.

Referenced by cftimer_create().

#define TIMER_MODE_CYCLES   2

Timer is in server cycles.

Definition at line 49 of file timers.h.

Referenced by cftimer_create(), and cftimer_process_timers().

#define TIMER_MODE_DEAD   0

Used to mark a timer as unused in the list.

Definition at line 47 of file timers.h.

Referenced by cftimer_create(), cftimer_destroy(), cftimer_find_free_id(), and cftimer_process_timers().

#define TIMER_MODE_SECONDS   1

Timer is in seconds.

Definition at line 48 of file timers.h.

Referenced by cftimer_create(), and cftimer_process_timers().

Typedef Documentation

typedef struct _cftimer cftimer

One timer.

Variable Documentation

cftimer timers_table[MAX_TIMERS]

The actual timers.

Definition at line 37 of file timers.c.