mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2025-09-21 04:56:01 +08:00
Added most recent version of unmodified HL2 SDK for Orange Box engine
This commit is contained in:
40
game/client/sdk/sdk_fx_weaponfx.cpp
Normal file
40
game/client/sdk/sdk_fx_weaponfx.cpp
Normal file
@ -0,0 +1,40 @@
|
||||
//========= Copyright <20> 1996-2005, Valve Corporation, All rights reserved. ============//
|
||||
//
|
||||
// Purpose: Game-specific impact effect hooks
|
||||
//
|
||||
//=============================================================================//
|
||||
#include "cbase.h"
|
||||
#include "fx_impact.h"
|
||||
#include "tempent.h"
|
||||
#include "c_te_effect_dispatch.h"
|
||||
#include "c_te_legacytempents.h"
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: Handle weapon effect callbacks
|
||||
//-----------------------------------------------------------------------------
|
||||
void SDK_EjectBrass( int shell, const CEffectData &data )
|
||||
{
|
||||
C_BasePlayer *pPlayer = C_BasePlayer::GetLocalPlayer();
|
||||
|
||||
if( !pPlayer )
|
||||
return;
|
||||
|
||||
tempents->CSEjectBrass( data.m_vOrigin, data.m_vAngles, data.m_fFlags, shell, pPlayer );
|
||||
}
|
||||
|
||||
void SDK_FX_EjectBrass_9mm_Callback( const CEffectData &data )
|
||||
{
|
||||
SDK_EjectBrass( CS_SHELL_9MM, data );
|
||||
}
|
||||
|
||||
void SDK_FX_EjectBrass_12Gauge_Callback( const CEffectData &data )
|
||||
{
|
||||
SDK_EjectBrass( CS_SHELL_12GAUGE, data );
|
||||
}
|
||||
|
||||
|
||||
|
||||
DECLARE_CLIENT_EFFECT( "EjectBrass_9mm", SDK_FX_EjectBrass_9mm_Callback );
|
||||
DECLARE_CLIENT_EFFECT( "EjectBrass_12Gauge",SDK_FX_EjectBrass_12Gauge_Callback );
|
||||
|
Reference in New Issue
Block a user