Subversion Repositories Kolibri OS

Rev

Rev 300 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 300 Rev 333
Line 24... Line 24...
24
rcsid[] = "$Id: m_bbox.c,v 1.1 1997/02/03 22:45:10 b1 Exp $";
24
rcsid[] = "$Id: m_bbox.c,v 1.1 1997/02/03 22:45:10 b1 Exp $";
Line 25... Line 25...
25
 
25
 
26
#include 
26
#include 
27
#include 
27
#include 
28
#include 
-
 
29
//#include "SDL.h"
-
 
Line 30... Line 28...
30
//#include "SDL_timer.h"
28
#include 
31
 
29
 
32
#include "doomdef.h"
30
#include "doomdef.h"
33
#include "m_misc.h"
31
#include "m_misc.h"
Line 37... Line 35...
37
#include "d_net.h"
35
#include "d_net.h"
38
#include "g_game.h"
36
#include "g_game.h"
Line 39... Line 37...
39
 
37
 
40
 
-
 
41
#include "i_system.h"
-
 
42
#include "kolibri.h"
-
 
Line -... Line 38...
-
 
38
 
Line 43... Line -...
43
 
-
 
44
int	mb_used = 6;
-
 
45
 
-
 
46
 
-
 
47
int I_strncasecmp(char *str1, char *str2, int len)
-
 
48
{
-
 
49
	char c1, c2;
39
#include "i_system.h"
50
 
-
 
51
	while ( *str1 && *str2 && len-- ) {
-
 
52
		c1 = *str1++;
-
 
53
		c2 = *str2++;
-
 
54
		if ( toupper(c1) != toupper(c2) )
-
 
Line 55... Line 40...
55
			return(1);
40
 
56
	}
41
#include "kolibri.h"
57
	return(0);
42
 
58
}
43
int     mb_used = 8;
Line 89... Line 74...
89
//
74
//
90
// I_GetTime
75
// I_GetTime
91
// returns time in 1/35 second tics
76
// returns time in 1/35 second tics
92
//
77
//
Line 93... Line -...
93
 
-
 
94
__declspec(dllimport) unsigned int __stdcall GetTickCount(void);
-
 
95
 
78
 
96
int  I_GetTime (void)
79
int  I_GetTime (void)
97
{
80
{
98
 unsigned int tm;
81
 unsigned int tm;
99
// _asm
82
 _asm
100
// {
83
 {  push ebx
101
//    mov eax, 26
84
    mov eax, 26
102
//    mov ebx, 9
85
    mov ebx, 9
103
//    int 0x40
86
    int 0x40
104
//    mov [tm], eax
87
    mov dword ptr [tm], eax
105
// };
-
 
106
 
-
 
107
 tm=GetTickCount()/10;
88
    pop ebx
Line 108... Line 89...
108
 
89
 };
109
 
90
 
Line 116... Line 97...
116
// I_Init
97
// I_Init
117
//
98
//
118
void I_Init (void)
99
void I_Init (void)
119
{
100
{
120
  I_InitGraphics();
101
  I_InitGraphics();
121
  I_InitSound();
102
 // I_InitSound();
122
}
103
}
Line 123... Line 104...
123
 
104
 
124
//
105
//
125
// I_Quit
106
// I_Quit
Line 146... Line 127...
146
 
127
 
147
void I_EndRead(void)
128
void I_EndRead(void)
148
{
129
{
Line -... Line 130...
-
 
130
}
149
}
131
 
150
 
132
/***********
151
byte*	I_AllocLow(int length)
133
byte*   I_AllocLow(int length)
Line 152... Line 134...
152
{
134
{
153
    byte*	mem;
135
    byte*       mem;
154
        
136
        
155
    mem = (byte *)malloc (length);
137
    mem = (byte *)malloc (length);
156
    memset (mem,0,length);
138
    memset (mem,0,length);
Line 157... Line 139...
157
    return mem;
139
    return mem;
158
}
140
}
159
 
141
************/
160
 
142
 
Line 168... Line 150...
168
    va_list	argptr;
150
    va_list     argptr;
Line 169... Line 151...
169
 
151
 
170
    // Message first.
152
    // Message first.
171
    va_start (argptr,error);
153
    va_start (argptr,error);
172
    printf ("Error: ");
154
    printf ("Error:  ");
173
    printf (argptr);
155
    printf (error,argptr);
174
    printf ("\n");
156
    printf ("\n\r");
Line 175... Line 157...
175
    va_end (argptr);
157
    va_end (argptr);
176
 
158
 
177
    // Shutdown. Here might be other errors.
159
    // Shutdown. Here might be other errors.