mirror of
https://github.com/nillerusr/source-engine.git
synced 2026-08-09 10:19:38 +00:00
fix some AddressSanitizer issues
This commit is contained in:
@@ -951,7 +951,7 @@ void PropBreakableCreateAll( int modelindex, IPhysicsObject *pPhysics, const bre
|
||||
nSkin = pOwnerAnim->m_nSkin;
|
||||
}
|
||||
}
|
||||
matrix3x4_t localToWorld;
|
||||
static matrix3x4_t localToWorld;
|
||||
|
||||
CStudioHdr studioHdr;
|
||||
const model_t *model = modelinfo->GetModel( modelindex );
|
||||
@@ -1009,7 +1009,7 @@ void PropBreakableCreateAll( int modelindex, IPhysicsObject *pPhysics, const bre
|
||||
if ( ( iPrecomputedBreakableCount != -1 ) && ( i >= iPrecomputedBreakableCount ) )
|
||||
break;
|
||||
|
||||
matrix3x4_t matrix;
|
||||
static matrix3x4_t matrix;
|
||||
AngleMatrix( params.angles, params.origin, matrix );
|
||||
|
||||
CStudioHdr studioHdr;
|
||||
@@ -1188,7 +1188,7 @@ void PropBreakableCreateAll( int modelindex, IPhysicsObject *pPhysics, const bre
|
||||
Vector vecBreakableObbSize = pBreakable->CollisionProp()->OBBSize();
|
||||
|
||||
// Try to align the gibs along the original axis
|
||||
matrix3x4_t matrix;
|
||||
static matrix3x4_t matrix;
|
||||
AngleMatrix( vecAngles, matrix );
|
||||
AlignBoxes( &matrix, vecObbSize, vecBreakableObbSize );
|
||||
MatrixAngles( matrix, vecAngles );
|
||||
@@ -1397,7 +1397,7 @@ CBaseEntity *CreateGibsFromList( CUtlVector<breakmodel_t> &list, int modelindex,
|
||||
if ( ( iPrecomputedBreakableCount != -1 ) && ( i >= iPrecomputedBreakableCount ) )
|
||||
break;
|
||||
|
||||
matrix3x4_t matrix;
|
||||
static matrix3x4_t matrix;
|
||||
AngleMatrix( params.angles, params.origin, matrix );
|
||||
|
||||
CStudioHdr studioHdr;
|
||||
@@ -1596,7 +1596,7 @@ CBaseEntity *CreateGibsFromList( CUtlVector<breakmodel_t> &list, int modelindex,
|
||||
Vector vecBreakableObbSize = pBreakable->CollisionProp()->OBBSize();
|
||||
|
||||
// Try to align the gibs along the original axis
|
||||
matrix3x4_t matrix;
|
||||
static matrix3x4_t matrix;
|
||||
AngleMatrix( vecAngles, matrix );
|
||||
AlignBoxes( &matrix, vecObbSize, vecBreakableObbSize );
|
||||
MatrixAngles( matrix, vecAngles );
|
||||
|
||||
@@ -221,7 +221,7 @@ struct breakmodel_t
|
||||
|
||||
struct breakablepropparams_t
|
||||
{
|
||||
breakablepropparams_t( const Vector &_origin, const QAngle &_angles, const Vector &_velocity, const AngularImpulse &_angularVelocity )
|
||||
breakablepropparams_t( const Vector _origin, const QAngle _angles, const Vector _velocity, const AngularImpulse _angularVelocity )
|
||||
: origin(_origin), angles(_angles), velocity(_velocity), angularVelocity(_angularVelocity)
|
||||
{
|
||||
impactEnergyScale = 0;
|
||||
@@ -230,10 +230,10 @@ struct breakablepropparams_t
|
||||
nDefaultSkin = 0;
|
||||
}
|
||||
|
||||
const Vector &origin;
|
||||
const QAngle &angles;
|
||||
const Vector &velocity;
|
||||
const AngularImpulse &angularVelocity;
|
||||
const Vector origin;
|
||||
const QAngle angles;
|
||||
const Vector velocity;
|
||||
const AngularImpulse angularVelocity;
|
||||
float impactEnergyScale;
|
||||
float defBurstScale;
|
||||
int defCollisionGroup;
|
||||
|
||||
Reference in New Issue
Block a user