summaryrefslogtreecommitdiff
path: root/src/qcommon/vm_local.h
diff options
context:
space:
mode:
authorZack Middleton <zturtleman@gmail.com>2012-12-15 21:55:07 +0000
committerTim Angus <tim@ngus.net>2013-01-12 21:26:42 +0000
commit91ae99ca4e1de95b54d9d3756f1c85a0abad4576 (patch)
tree820e37bf8e5ab37dffb48288aad96c77b11cb90a /src/qcommon/vm_local.h
parentaf4982fd82a5de4ae80557460ea7e2f17e7cbda9 (diff)
Fix passing arg9 (qvm only), arg10, and arg11 to vmMain for native libs and non-i386 compiled or interpated qvms. (Currently they aren't use in vmMain in game, cgame, or ui.) Fix passing args[11] to args[15] from vm to engine on ppc64 and sparc64. Some of the args are used by game bot prediction syscalls. May have been causing bugs. Note: This was fixed for x86_64 in r2163.
Diffstat (limited to 'src/qcommon/vm_local.h')
-rw-r--r--src/qcommon/vm_local.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/qcommon/vm_local.h b/src/qcommon/vm_local.h
index 7560832c..5e00c0de 100644
--- a/src/qcommon/vm_local.h
+++ b/src/qcommon/vm_local.h
@@ -23,6 +23,14 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#include "q_shared.h"
#include "qcommon.h"
+// Max number of arguments to pass from engine to vm's vmMain function.
+// command number + 12 arguments
+#define MAX_VMMAIN_ARGS 13
+
+// Max number of arguments to pass from a vm to engine's syscall handler function for the vm.
+// syscall number + 15 arguments
+#define MAX_VMSYSCALL_ARGS 16
+
// don't change, this is hardcoded into x86 VMs, opStack protection relies
// on this
#define OPSTACK_SIZE 1024