forked from KolibriOS/kolibrios
sdlquake:
- Better fix for finding resource folders. git-svn-id: svn://kolibrios.org@8663 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
e54c8af781
commit
9aefaa6765
@ -834,11 +834,6 @@ Host_Init
|
||||
*/
|
||||
void Host_Init (quakeparms_t *parms)
|
||||
{
|
||||
#ifdef _KOLIBRI
|
||||
#include "dirname.c"
|
||||
parms->basedir=dirname(parms->argv[0]);
|
||||
#endif
|
||||
|
||||
if (standard_quake)
|
||||
minimum_memory = MINIMUM_MEMORY;
|
||||
else
|
||||
|
@ -1,3 +1,6 @@
|
||||
#ifndef _KOLIBRI_H_
|
||||
#define _KOLIBRI_H_
|
||||
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
@ -47,4 +50,13 @@ char *dirname (char *path)
|
||||
found and so a static and constant string is required. */
|
||||
path = (char *) dot;
|
||||
return path;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void _ksys_setcwd(char* dir){
|
||||
__asm__ __volatile__ (
|
||||
"int $0x40"
|
||||
::"a"(30), "b"(1), "c"(dir)
|
||||
);
|
||||
};
|
||||
#endif
|
@ -384,6 +384,10 @@ void moncontrol(int x)
|
||||
|
||||
int main (int c, char **v)
|
||||
{
|
||||
#ifdef _KOLIBRI
|
||||
#include "kolibri.h"
|
||||
_ksys_setcwd(dirname(v[0]));
|
||||
#endif
|
||||
|
||||
double time, oldtime, newtime;
|
||||
quakeparms_t parms;
|
||||
|
Loading…
Reference in New Issue
Block a user