1 /*------------------------------------------------------------------
4 XINVADERS 3D - 3d Shoot'em up
5 Copyright (C) 2000 Don Llopis
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 ------------------------------------------------------------------*/
22 #ifndef GAME_SYSTEM_FUNCTIONS
23 #define GAME_SYSTEM_FUNCTIONS
25 /*------------------------------------------------------------------
27 * Misc Functions & Graphics primitives:
28 * LINUX/X11 : main-x11.c
30 ------------------------------------------------------------------*/
32 #define WIN_HEIGHT 480
33 #define MAX_COLORS 256
35 extern int Graphics_init ( unsigned int, unsigned int );
36 extern void Graphics_shutdown ( void );
37 extern int Update_display ( void );
38 extern int Handle_events ( void );
39 extern void Draw_line ( int, int, int, int, unsigned int );
40 extern void Draw_point ( int, int, unsigned int );
41 extern void Draw_text ( char *, int, int, unsigned int );
43 /*------------------------------------------------------------------
45 * System msec & sec Timer functions:
46 * LINUX/X11 : main-x11.c
48 ------------------------------------------------------------------*/
53 #include <sys/times.h>
54 #include <sys/types.h>
56 #define TIMEVAL struct timeval
57 #define CLOCK_T clock_t
62 #include <sys/times.h>
63 #include <sys/types.h>
65 #define TIMEVAL struct timeval
66 #define CLOCK_T clock_t
73 #define TIMEVAL struct timeval
74 #define CLOCK_T clock_t
80 #define TIMEVAL struct timeval
81 #define CLOCK_T clock_t
85 typedef struct TIMERSTRUCT TIMER
;
88 TIME_T init_time_stamp
;
93 extern void Timer_init ( TIMER
* );
94 extern CLOCK_T
Timer_ticks ( void );
95 extern double Timer_sec ( TIMER
* );
96 extern long Timer_msec ( TIMER
* );