diff options
| author | Joe Ludwig <[email protected]> | 2013-06-26 15:22:04 -0700 |
|---|---|---|
| committer | Joe Ludwig <[email protected]> | 2013-06-26 15:22:04 -0700 |
| commit | 39ed87570bdb2f86969d4be821c94b722dc71179 (patch) | |
| tree | abc53757f75f40c80278e87650ea92808274aa59 /mp/src/game/shared/sdk/sdk_weapon_parse.cpp | |
| download | source-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.tar.xz source-sdk-2013-39ed87570bdb2f86969d4be821c94b722dc71179.zip | |
First version of the SOurce SDK 2013
Diffstat (limited to 'mp/src/game/shared/sdk/sdk_weapon_parse.cpp')
| -rw-r--r-- | mp/src/game/shared/sdk/sdk_weapon_parse.cpp | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/mp/src/game/shared/sdk/sdk_weapon_parse.cpp b/mp/src/game/shared/sdk/sdk_weapon_parse.cpp new file mode 100644 index 00000000..1e122b7c --- /dev/null +++ b/mp/src/game/shared/sdk/sdk_weapon_parse.cpp @@ -0,0 +1,35 @@ +//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose:
+//
+//=============================================================================//
+
+#include "cbase.h"
+#include <KeyValues.h>
+#include "sdk_weapon_parse.h"
+
+
+FileWeaponInfo_t* CreateWeaponInfo()
+{
+ return new CSDKWeaponInfo;
+}
+
+
+CSDKWeaponInfo::CSDKWeaponInfo()
+{
+}
+
+
+void CSDKWeaponInfo::Parse( KeyValues *pKeyValuesData, const char *szWeaponName )
+{
+ BaseClass::Parse( pKeyValuesData, szWeaponName );
+
+ m_iDamage = pKeyValuesData->GetInt( "Damage", 42 ); // Douglas Adams 1952 - 2001
+ m_iBullets = pKeyValuesData->GetInt( "Bullets", 1 );
+ m_flCycleTime = pKeyValuesData->GetFloat( "CycleTime", 0.15 );
+
+ const char *pAnimEx = pKeyValuesData->GetString( "PlayerAnimationExtension", "mp5" );
+ Q_strncpy( m_szAnimExtension, pAnimEx, sizeof( m_szAnimExtension ) );
+}
+
+
|