Andrey Akhmichin 4 years ago
parent
commit
4c19cb7c8c
  1. 12
      dlls/hunger/medkit.cpp
  2. 1
      dlls/weapons.h

12
dlls/hunger/medkit.cpp

@ -72,6 +72,18 @@ int CWeaponEinarMedkit::GetItemInfo( ItemInfo *p ) @@ -72,6 +72,18 @@ int CWeaponEinarMedkit::GetItemInfo( ItemInfo *p )
return 1;
}
int CWeaponEinarMedkit::AddToPlayer( CBasePlayer *pPlayer )
{
if( CBasePlayerWeapon::AddToPlayer( pPlayer ) )
{
MESSAGE_BEGIN( MSG_ONE, gmsgWeapPickup, NULL, pPlayer->pev );
WRITE_BYTE( m_iId );
MESSAGE_END();
return TRUE;
}
return FALSE;
}
BOOL CWeaponEinarMedkit::Deploy()
{
return DefaultDeploy( "models/v_tfc_medkit.mdl", "models/p_tfc_medkit.mdl", MEDKIT_DRAW, "trip" );

1
dlls/weapons.h

@ -1248,6 +1248,7 @@ public: @@ -1248,6 +1248,7 @@ public:
void Spawn();
void Precache();
int iItemSlot() { return 5; }
int AddToPlayer( CBasePlayer *pPlayer );
int GetItemInfo( ItemInfo *p );
void PrimaryAttack();

Loading…
Cancel
Save