Asset Fixes

This commit is contained in:
Grant Bagwell 2020-11-30 21:41:28 +01:00
parent 7a66df5945
commit 347efca8fc
3 changed files with 28 additions and 22 deletions

View file

@ -985,6 +985,7 @@ idAFEntity_Gibbable::idAFEntity_Gibbable( void ) {
skeletonModel = NULL; skeletonModel = NULL;
skeletonModelDefHandle = -1; skeletonModelDefHandle = -1;
gibbed = false; gibbed = false;
wasThrown = false;
} }
/* /*
@ -1007,6 +1008,7 @@ idAFEntity_Gibbable::Save
void idAFEntity_Gibbable::Save( idSaveGame *savefile ) const { void idAFEntity_Gibbable::Save( idSaveGame *savefile ) const {
savefile->WriteBool( gibbed ); savefile->WriteBool( gibbed );
savefile->WriteBool( combatModel != NULL ); savefile->WriteBool( combatModel != NULL );
savefile->WriteBool( wasThrown );
} }
/* /*
@ -1019,6 +1021,7 @@ void idAFEntity_Gibbable::Restore( idRestoreGame *savefile ) {
savefile->ReadBool( gibbed ); savefile->ReadBool( gibbed );
savefile->ReadBool( hasCombatModel ); savefile->ReadBool( hasCombatModel );
savefile->ReadBool( wasThrown );
InitSkeletonModel(); InitSkeletonModel();
@ -1037,6 +1040,7 @@ void idAFEntity_Gibbable::Spawn( void ) {
InitSkeletonModel(); InitSkeletonModel();
gibbed = false; gibbed = false;
wasThrown = false;
} }
/* /*
@ -1232,6 +1236,9 @@ void idAFEntity_Gibbable::Gib( const idVec3 &dir, const char *damageDefName ) {
return; return;
} }
// Don't grab this ent after it's been gibbed (and now invisible!)
noGrab = true;
const idDict *damageDef = gameLocal.FindEntityDefDict( damageDefName ); const idDict *damageDef = gameLocal.FindEntityDefDict( damageDefName );
if ( !damageDef ) { if ( !damageDef ) {
gameLocal.Error( "Unknown damageDef '%s'", damageDefName ); gameLocal.Error( "Unknown damageDef '%s'", damageDefName );

View file

@ -273,8 +273,7 @@ typedef enum {
} materialFlags_t; } materialFlags_t;
// contents flags, NOTE: make sure to keep the defines in doom_defs.script up to date with these! // contents flags, NOTE: make sure to keep the defines in doom_defs.script up to date with these!
typedef enum typedef enum {
{
CONTENTS_SOLID = BIT(0), // an eye is never valid in a solid CONTENTS_SOLID = BIT(0), // an eye is never valid in a solid
CONTENTS_OPAQUE = BIT(1), // blocks visibility (for ai) CONTENTS_OPAQUE = BIT(1), // blocks visibility (for ai)
CONTENTS_WATER = BIT(2), // used for water CONTENTS_WATER = BIT(2), // used for water
@ -296,7 +295,7 @@ typedef enum
CONTENTS_AREAPORTAL = BIT(20), // portal separating renderer areas CONTENTS_AREAPORTAL = BIT(20), // portal separating renderer areas
CONTENTS_NOCSG = BIT(21), // don't cut this brush with CSG operations in the editor CONTENTS_NOCSG = BIT(21), // don't cut this brush with CSG operations in the editor
CONTENTS_REMOVE_UTIL = (int)(~( CONTENTS_AREAPORTAL | CONTENTS_NOCSG )) CONTENTS_REMOVE_UTIL = ~(CONTENTS_AREAPORTAL|CONTENTS_NOCSG)
} contentsFlags_t; } contentsFlags_t;
// surface types // surface types

Binary file not shown.