[iortcw] 213/497: All: Add some missing QVM defines
Simon McVittie
smcv at debian.org
Fri Sep 8 10:36:53 UTC 2017
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to annotated tag 1.42d
in repository iortcw.
commit 9fd3eef5d8e12c11351bcc83a27838170bef6ad0
Author: M4N4T4RMS at gmail.com <M4N4T4RMS at gmail.com@e65d2741-a53d-b2dc-ae96-bb75fa5e4c4a>
Date: Thu Sep 11 23:56:22 2014 +0000
All: Add some missing QVM defines
---
MP/code/cgame/cg_syscalls.c | 4 ++++
MP/code/game/bg_misc.c | 8 +++++++-
MP/code/game/g_syscalls.c | 3 +++
MP/code/ui/ui_syscalls.c | 3 +++
SP/Makefile | 2 +-
SP/code/cgame/cg_syscalls.c | 4 ++++
SP/code/game/bg_misc.c | 8 +++++++-
SP/code/ui/ui_syscalls.c | 3 +++
8 files changed, 32 insertions(+), 3 deletions(-)
diff --git a/MP/code/cgame/cg_syscalls.c b/MP/code/cgame/cg_syscalls.c
index 7317b43..9a72457 100644
--- a/MP/code/cgame/cg_syscalls.c
+++ b/MP/code/cgame/cg_syscalls.c
@@ -28,6 +28,10 @@ If you have questions concerning this license or the applicable additional terms
// cg_syscalls.c -- this file is only included when building a dll
// cg_syscalls.asm is included instead when building a qvm
+#ifdef Q3_VM
+#error "Do not use in VM build"
+#endif
+
#include "cg_local.h"
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
diff --git a/MP/code/game/bg_misc.c b/MP/code/game/bg_misc.c
index 4fe390e..82c2a61 100644
--- a/MP/code/game/bg_misc.c
+++ b/MP/code/game/bg_misc.c
@@ -3490,7 +3490,13 @@ qboolean BG_CanItemBeGrabbed( const entityState_t *ent, const playerState_t *
case IT_BAD:
Com_Error( ERR_DROP, "BG_CanItemBeGrabbed: IT_BAD" );
-
+ default:
+#ifndef Q3_VM
+#ifndef NDEBUG
+ Com_Printf("BG_CanItemBeGrabbed: unknown enum %d\n", item->giType );
+#endif
+#endif
+ break;
}
return qfalse;
}
diff --git a/MP/code/game/g_syscalls.c b/MP/code/game/g_syscalls.c
index a683e08..7b5b701 100644
--- a/MP/code/game/g_syscalls.c
+++ b/MP/code/game/g_syscalls.c
@@ -30,6 +30,9 @@ If you have questions concerning this license or the applicable additional terms
// this file is only included when building a dll
// g_syscalls.asm is included instead when building a qvm
+#ifdef Q3_VM
+#error "Do not use in VM build"
+#endif
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
diff --git a/MP/code/ui/ui_syscalls.c b/MP/code/ui/ui_syscalls.c
index 963efbb..672d599 100644
--- a/MP/code/ui/ui_syscalls.c
+++ b/MP/code/ui/ui_syscalls.c
@@ -30,6 +30,9 @@ If you have questions concerning this license or the applicable additional terms
// this file is only included when building a dll
// syscalls.asm is included instead when building a qvm
+#ifdef Q3_VM
+#error "Do not use in VM build"
+#endif
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
diff --git a/SP/Makefile b/SP/Makefile
index 4896b0a..c4ee463 100644
--- a/SP/Makefile
+++ b/SP/Makefile
@@ -30,7 +30,7 @@ ifndef BUILD_GAME_SO
BUILD_GAME_SO =
endif
ifndef BUILD_GAME_QVM
- BUILD_GAME_QVM = 0
+ BUILD_GAME_QVM =
endif
ifndef BUILD_BASEGAME
BUILD_BASEGAME =
diff --git a/SP/code/cgame/cg_syscalls.c b/SP/code/cgame/cg_syscalls.c
index be241f5..988cda8 100644
--- a/SP/code/cgame/cg_syscalls.c
+++ b/SP/code/cgame/cg_syscalls.c
@@ -28,6 +28,10 @@ If you have questions concerning this license or the applicable additional terms
// cg_syscalls.c -- this file is only included when building a dll
// cg_syscalls.asm is included instead when building a qvm
+#ifdef Q3_VM
+#error "Do not use in VM build"
+#endif
+
#include "cg_local.h"
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
diff --git a/SP/code/game/bg_misc.c b/SP/code/game/bg_misc.c
index d63bb90..98f6464 100644
--- a/SP/code/game/bg_misc.c
+++ b/SP/code/game/bg_misc.c
@@ -3973,7 +3973,13 @@ qboolean BG_CanItemBeGrabbed( const entityState_t *ent, const playerState_t *
case IT_BAD:
Com_Error( ERR_DROP, "BG_CanItemBeGrabbed: IT_BAD" );
-
+ default:
+#ifndef Q3_VM
+#ifndef NDEBUG
+ Com_Printf("BG_CanItemBeGrabbed: unknown enum %d\n", item->giType );
+#endif
+#endif
+ break;
}
return qfalse;
diff --git a/SP/code/ui/ui_syscalls.c b/SP/code/ui/ui_syscalls.c
index 4dece35..4edc176 100644
--- a/SP/code/ui/ui_syscalls.c
+++ b/SP/code/ui/ui_syscalls.c
@@ -30,6 +30,9 @@ If you have questions concerning this license or the applicable additional terms
// this file is only included when building a dll
// syscalls.asm is included instead when building a qvm
+#ifdef Q3_VM
+#error "Do not use in VM build"
+#endif
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/iortcw.git
More information about the Pkg-games-commits
mailing list