fix two 'wrong number of parameters' errors
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 19 Feb 2007 05:53:11 +0000 (05:53 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 19 Feb 2007 05:53:11 +0000 (05:53 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6865 d7cf8633-e32d-0410-b094-e92efae38249

prvm_cmds.c
svvm_cmds.c

index 887192d..3e4a4af 100644 (file)
@@ -3596,7 +3596,9 @@ void VM_changeyaw (void)
        prvm_edict_t            *ent;
        float           ideal, current, move, speed;
 
-       VM_SAFEPARMCOUNT(0, VM_changeyaw);
+       // this is called (VERY HACKISHLY) by SV_MoveToGoal, so it can not use any
+       // parameters because they are the parameters to SV_MoveToGoal, not this
+       //VM_SAFEPARMCOUNT(0, VM_changeyaw);
 
        ent = PRVM_PROG_TO_EDICT(PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict);
        if (ent == prog->edicts)
index 2a1cb18..9be2ed7 100644 (file)
@@ -963,7 +963,7 @@ VM_SV_checkbottom
 */
 static void VM_SV_checkbottom (void)
 {
-       VM_SAFEPARMCOUNT(0, VM_SV_checkbottom);
+       VM_SAFEPARMCOUNT(1, VM_SV_checkbottom);
        PRVM_G_FLOAT(OFS_RETURN) = SV_CheckBottom (PRVM_G_EDICT(OFS_PARM0));
 }