Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

77 lines
1.3 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose: Holds defintion for game ammo types
  4. //
  5. // $Workfile: $
  6. // $Date: $
  7. // $NoKeywords: $
  8. //=============================================================================//
  9. #ifndef CS_BLACKMARKET_H
  10. #define CS_BLACKMARKET_H
  11. #include "cs_weapon_parse.h"
  12. #ifdef CLIENT_DLL
  13. #include "c_cs_player.h"
  14. #else
  15. #include "cs_player.h"
  16. #endif
  17. #ifdef _WIN32
  18. #pragma once
  19. #endif
  20. struct blackmarket_items_t
  21. {
  22. const char *pClassname;
  23. int iDefaultPrice;
  24. };
  25. extern blackmarket_items_t blackmarket_items[];
  26. void BlackMarketAddWeapon( const char *pWeaponName, CCSPlayer *pBuyer );
  27. #ifndef CLIENT_DLL
  28. class CBlackMarketElement
  29. {
  30. public:
  31. DECLARE_CLASS_NOBASE( CBlackMarketElement );
  32. // For CNetworkVars.
  33. void NetworkStateChanged();
  34. void NetworkStateChanged( void *pVar );
  35. CBlackMarketElement()
  36. {
  37. m_iPrice = 0;
  38. m_iTimesBought = 0;
  39. m_iWeaponID = 0;
  40. }
  41. CNetworkVar( int, m_iPrice );
  42. CNetworkVar( int, m_iWeaponID );
  43. int m_iTimesBought;
  44. };
  45. #else
  46. class C_BlackMarketElement
  47. {
  48. public:
  49. // This allows the datatables to access private members.
  50. ALLOW_DATATABLES_PRIVATE_ACCESS();
  51. int m_iWeaponID;
  52. int m_iPrice;
  53. };
  54. #define CBlackMarketElement C_BlackMarketElement
  55. #endif
  56. #endif // CS_BLACKMARKET_H