mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-29 16:24:16 +00:00
engine: fix build
This commit is contained in:
parent
e6a2c207de
commit
e44718d531
@ -306,7 +306,7 @@ void Host_NewInstance( const char *name, const char *finalmsg )
|
|||||||
host.change_game = true;
|
host.change_game = true;
|
||||||
Q_strncpy( host.finalmsg, finalmsg, sizeof( host.finalmsg ));
|
Q_strncpy( host.finalmsg, finalmsg, sizeof( host.finalmsg ));
|
||||||
|
|
||||||
if( !Platform_ChangeGame( name ))
|
if( !Sys_NewInstance( name ))
|
||||||
pChangeGame( name ); // call from hl.exe
|
pChangeGame( name ); // call from hl.exe
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -47,7 +47,7 @@ static void Sys_ChangeGame( const char *progname )
|
|||||||
// if platform supports execv() function
|
// if platform supports execv() function
|
||||||
Q_strncpy( szGameDir, progname, sizeof( szGameDir ) - 1 );
|
Q_strncpy( szGameDir, progname, sizeof( szGameDir ) - 1 );
|
||||||
Host_Shutdown( );
|
Host_Shutdown( );
|
||||||
exit( Host_Main( szArgc, szArgv, szGameDir, 1, &Launcher_ChangeGame ) );
|
exit( Host_Main( szArgc, szArgv, szGameDir, 1, &Sys_ChangeGame ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
_inline int Sys_Start( void )
|
_inline int Sys_Start( void )
|
||||||
@ -81,7 +81,7 @@ _inline int Sys_Start( void )
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
ret = Host_Main( szArgc, szArgv, game, 0, Launcher_ChangeGame );
|
ret = Host_Main( szArgc, szArgv, game, 0, Sys_ChangeGame );
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -17,6 +17,7 @@ GNU General Public License for more details.
|
|||||||
#include "xash3d_mathlib.h"
|
#include "xash3d_mathlib.h"
|
||||||
#include "platform/platform.h"
|
#include "platform/platform.h"
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
#include <errno.h>
|
||||||
|
|
||||||
#ifdef XASH_SDL
|
#ifdef XASH_SDL
|
||||||
#include <SDL.h>
|
#include <SDL.h>
|
||||||
@ -556,7 +557,7 @@ but since engine will be unloaded during this call
|
|||||||
it explicitly doesn't use internal allocation or string copy utils
|
it explicitly doesn't use internal allocation or string copy utils
|
||||||
==================
|
==================
|
||||||
*/
|
*/
|
||||||
qboolean Sys_ChangeGame( const char *gamedir )
|
qboolean Sys_NewInstance( const char *gamedir )
|
||||||
{
|
{
|
||||||
int i = 0;
|
int i = 0;
|
||||||
qboolean replacedArg = false;
|
qboolean replacedArg = false;
|
||||||
|
@ -68,6 +68,7 @@ void Sys_PrintLog( const char *pMsg );
|
|||||||
void Sys_InitLog( void );
|
void Sys_InitLog( void );
|
||||||
void Sys_CloseLog( void );
|
void Sys_CloseLog( void );
|
||||||
void Sys_Quit( void ) NORETURN;
|
void Sys_Quit( void ) NORETURN;
|
||||||
|
qboolean Sys_NewInstance( const char *gamedir );
|
||||||
|
|
||||||
//
|
//
|
||||||
// sys_con.c
|
// sys_con.c
|
||||||
|
Loading…
x
Reference in New Issue
Block a user