jedi-academy/code/client/vmachine.cpp

40 lines
868 B
C++
Raw Normal View History

2013-04-19 02:52:48 +00:00
// vmachine.cpp -- wrapper to fake virtual machine for client
#include "vmachine.h"
#pragma warning (disable : 4514)
/*
==============================================================
VIRTUAL MACHINE
==============================================================
*/
int VM_Call( int callnum, ... )
{
// assert (cgvm.entryPoint);
if (cgvm.entryPoint)
{
return cgvm.entryPoint( (&callnum)[0], (&callnum)[1], (&callnum)[2], (&callnum)[3],
(&callnum)[4], (&callnum)[5], (&callnum)[6], (&callnum)[7],
(&callnum)[8], (&callnum)[9] );
}
return -1;
}
/*
============
VM_DllSyscall
we pass this to the cgame dll to call back into the client
============
*/
extern int CL_CgameSystemCalls( int *args );
extern int CL_UISystemCalls( int *args );
int VM_DllSyscall( int arg, ... ) {
// return cgvm->systemCall( &arg );
return CL_CgameSystemCalls( &arg );
}