Reset gibsthisframe and lastgibframe at map change

Without this change the conditionals at g_misc.c:199 and 381 wouldn't
trigger until level.framenum reach it's previous value, resulting in
much to few debris or gibs being thrown. This fixes #104.

Many thanks to maraakate for the analysis and the idea how to fix it.
This commit is contained in:
Yamagi Burmeister 2015-10-24 13:30:41 +02:00
parent ef8882e106
commit 291d9852ee
3 changed files with 21 additions and 15 deletions

View File

@ -380,6 +380,9 @@ ExitLevel(void)
ent->health = ent->client->pers.max_health;
}
}
gibsthisframe = 0;
lastgibframe = 0;
}
/*

View File

@ -7,8 +7,8 @@
#include "header/local.h"
int gibsthisframe = 0;
int lastgibframe = 0;
int gibsthisframe;
int lastgibframe;
/*
* QUAKED func_group (0 0 0) ?

View File

@ -428,6 +428,9 @@ extern spawn_temp_t st;
extern int sm_meat_index;
extern int snd_fry;
extern int gibsthisframe;
extern int lastgibframe;
/* means of death */
#define MOD_UNKNOWN 0
#define MOD_BLASTER 1