summaryrefslogtreecommitdiff
path: root/src/game
diff options
context:
space:
mode:
authorPaweł Redman <pawel.redman@gmail.com>2015-11-29 19:58:18 +0100
committerPaweł Redman <pawel.redman@gmail.com>2015-11-29 19:58:18 +0100
commitb86cbd75d8ff0e1606c041b5ed77c340cb802715 (patch)
tree845932611591d0c13d76d9c0a8624b6af5547557 /src/game
parent1509124dc819fadf68ffc53e2369258bafcda5b5 (diff)
Port cgame and game to 1.1 ABI.
Diffstat (limited to 'src/game')
-rw-r--r--src/game/bg_misc.c7
-rw-r--r--src/game/g_main.c13
-rw-r--r--src/game/g_public.h7
-rw-r--r--src/game/g_syscalls.asm121
-rw-r--r--src/game/g_syscalls.c16
5 files changed, 80 insertions, 84 deletions
diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c
index b5bd305..f6721f5 100644
--- a/src/game/bg_misc.c
+++ b/src/game/bg_misc.c
@@ -5238,3 +5238,10 @@ qboolean BG_ForceFieldForEntity( playerState_t *ps, entityState_t *es, forceFiel
return qfalse;
}
+
+// missing syscalls
+
+int trap_S_SoundDuration( sfxHandle_t handle )
+{
+ return 1000;
+}
diff --git a/src/game/g_main.c b/src/game/g_main.c
index 1efc039..2923ff3 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -2961,3 +2961,16 @@ void G_RunFrame( int levelTime )
level.frameMsec = trap_Milliseconds();
}
+// missing syscalls
+
+void trap_SetConfigstringRestrictions( int num, const clientList_t *clientList )
+{
+}
+
+void trap_AddCommand( const char *cmdName )
+{
+}
+
+void trap_RemoveCommand( const char *cmdName )
+{
+}
diff --git a/src/game/g_public.h b/src/game/g_public.h
index 9512574..effbe37 100644
--- a/src/game/g_public.h
+++ b/src/game/g_public.h
@@ -159,8 +159,6 @@ typedef enum {
G_GET_CONFIGSTRING, // ( int num, char *buffer, int bufferSize );
- G_SET_CONFIGSTRING_RESTRICTIONS, // ( int num, const clientList* clientList );
-
G_GET_USERINFO, // ( int num, char *buffer, int bufferSize );
// userinfo strings are maintained by the server system, so they
// are persistant across level loads, while all other game visible
@@ -226,10 +224,7 @@ typedef enum {
G_PARSE_READ_TOKEN,
G_PARSE_SOURCE_FILE_AND_LINE,
- G_SEND_GAMESTAT,
-
- G_ADDCOMMAND,
- G_REMOVECOMMAND
+ G_SEND_GAMESTAT
} gameImport_t;
diff --git a/src/game/g_syscalls.asm b/src/game/g_syscalls.asm
index f39b138..132ca1e 100644
--- a/src/game/g_syscalls.asm
+++ b/src/game/g_syscalls.asm
@@ -1,68 +1,65 @@
code
-equ trap_Print -1
-equ trap_Error -2
-equ trap_Milliseconds -3
-equ trap_Cvar_Register -4
-equ trap_Cvar_Update -5
-equ trap_Cvar_Set -6
-equ trap_Cvar_VariableIntegerValue -7
-equ trap_Cvar_VariableStringBuffer -8
-equ trap_Argc -9
-equ trap_Argv -10
-equ trap_FS_FOpenFile -11
-equ trap_FS_Read -12
-equ trap_FS_Write -13
-equ trap_FS_FCloseFile -14
-equ trap_SendConsoleCommand -15
-equ trap_LocateGameData -16
-equ trap_DropClient -17
-equ trap_SendServerCommand -18
-equ trap_SetConfigstring -19
-equ trap_GetConfigstring -20
-equ trap_SetConfigstringRestrictions -21
-equ trap_GetUserinfo -22
-equ trap_SetUserinfo -23
-equ trap_GetServerinfo -24
-equ trap_SetBrushModel -25
-equ trap_Trace -26
-equ trap_PointContents -27
-equ trap_InPVS -28
-equ trap_InPVSIgnorePortals -29
-equ trap_AdjustAreaPortalState -30
-equ trap_AreasConnected -31
-equ trap_LinkEntity -32
-equ trap_UnlinkEntity -33
-equ trap_EntitiesInBox -34
-equ trap_EntityContact -35
-equ trap_GetUsercmd -36
-equ trap_GetEntityToken -37
-equ trap_FS_GetFileList -38
-equ trap_RealTime -39
-equ trap_SnapVector -40
-equ trap_TraceCapsule -41
-equ trap_EntityContactCapsule -42
-equ trap_FS_Seek -43
+equ trap_Print -1
+equ trap_Error -2
+equ trap_Milliseconds -3
+equ trap_Cvar_Register -4
+equ trap_Cvar_Update -5
+equ trap_Cvar_Set -6
+equ trap_Cvar_VariableIntegerValue -7
+equ trap_Cvar_VariableStringBuffer -8
+equ trap_Argc -9
+equ trap_Argv -10
+equ trap_FS_FOpenFile -11
+equ trap_FS_Read -12
+equ trap_FS_Write -13
+equ trap_FS_FCloseFile -14
+equ trap_SendConsoleCommand -15
+equ trap_LocateGameData -16
+equ trap_DropClient -17
+equ trap_SendServerCommand -18
+equ trap_SetConfigstring -19
+equ trap_GetConfigstring -20
+equ trap_GetUserinfo -21
+equ trap_SetUserinfo -22
+equ trap_GetServerinfo -23
+equ trap_SetBrushModel -24
+equ trap_Trace -25
+equ trap_PointContents -26
+equ trap_InPVS -27
+equ trap_InPVSIgnorePortals -28
+equ trap_AdjustAreaPortalState -29
+equ trap_AreasConnected -30
+equ trap_LinkEntity -31
+equ trap_UnlinkEntity -32
+equ trap_EntitiesInBox -33
+equ trap_EntityContact -34
+equ trap_GetUsercmd -35
+equ trap_GetEntityToken -36
+equ trap_FS_GetFileList -37
+equ trap_RealTime -38
+equ trap_SnapVector -39
+equ trap_TraceCapsule -40
+equ trap_EntityContactCapsule -41
+equ trap_FS_Seek -42
-equ trap_Parse_AddGlobalDefine -44
-equ trap_Parse_LoadSource -45
-equ trap_Parse_FreeSource -46
-equ trap_Parse_ReadToken -47
-equ trap_Parse_SourceFileAndLine -48
+equ trap_Parse_AddGlobalDefine -43
+equ trap_Parse_LoadSource -44
+equ trap_Parse_FreeSource -45
+equ trap_Parse_ReadToken -46
+equ trap_Parse_SourceFileAndLine -47
-equ trap_SendGameStat -49
+equ trap_SendGameStat -48
-equ trap_AddCommand -50
-equ trap_RemoveCommand -51
-equ memset -101
-equ memcpy -102
-equ strncpy -103
-equ sin -104
-equ cos -105
-equ atan2 -106
-equ sqrt -107
-equ floor -111
-equ ceil -112
-equ testPrintInt -113
-equ testPrintFloat -114
+equ memset -101
+equ memcpy -102
+equ strncpy -103
+equ sin -104
+equ cos -105
+equ atan2 -106
+equ sqrt -107
+equ floor -111
+equ ceil -112
+equ testPrintInt -113
+equ testPrintFloat -114
diff --git a/src/game/g_syscalls.c b/src/game/g_syscalls.c
index 800bd2a..4ec48d3 100644
--- a/src/game/g_syscalls.c
+++ b/src/game/g_syscalls.c
@@ -151,11 +151,6 @@ void trap_GetConfigstring( int num, char *buffer, int bufferSize )
syscall( G_GET_CONFIGSTRING, num, buffer, bufferSize );
}
-void trap_SetConfigstringRestrictions( int num, const clientList_t *clientList )
-{
- syscall( G_SET_CONFIGSTRING_RESTRICTIONS, num, clientList );
-}
-
void trap_GetUserinfo( int num, char *buffer, int bufferSize )
{
syscall( G_GET_USERINFO, num, buffer, bufferSize );
@@ -290,14 +285,3 @@ int trap_Parse_SourceFileAndLine( int handle, char *filename, int *line )
{
return syscall( G_PARSE_SOURCE_FILE_AND_LINE, handle, filename, line );
}
-
-void trap_AddCommand( const char *cmdName )
-{
- syscall( G_ADDCOMMAND, cmdName );
-}
-
-void trap_RemoveCommand( const char *cmdName )
-{
- syscall( G_REMOVECOMMAND, cmdName );
-}
-