mirror of
https://github.com/celisej567/source-sdk-2013.git
synced 2026-09-17 20:10:21 +03:00
Added weapon script keyvalues for unique dropped model and whether or not to use the separate hands model
This commit is contained in:
@@ -125,9 +125,15 @@ void C_BaseCombatWeapon::OnRestore()
|
||||
|
||||
int C_BaseCombatWeapon::GetWorldModelIndex( void )
|
||||
{
|
||||
#ifdef MAPBASE
|
||||
int iIndex = GetOwner() ? m_iWorldModelIndex.Get() : m_iDroppedModelIndex.Get();
|
||||
#else
|
||||
int iIndex = m_iWorldModelIndex.Get();
|
||||
#endif
|
||||
|
||||
if ( GameRules() )
|
||||
{
|
||||
const char *pBaseName = modelinfo->GetModelName( modelinfo->GetModel( m_iWorldModelIndex ) );
|
||||
const char *pBaseName = modelinfo->GetModelName( modelinfo->GetModel( iIndex ) );
|
||||
const char *pTranslatedName = GameRules()->TranslateEffectForVisionFilter( "weapons", pBaseName );
|
||||
|
||||
if ( pTranslatedName != pBaseName )
|
||||
@@ -136,7 +142,7 @@ int C_BaseCombatWeapon::GetWorldModelIndex( void )
|
||||
}
|
||||
}
|
||||
|
||||
return m_iWorldModelIndex;
|
||||
return iIndex;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user