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.

108 lines
4.1 KiB

  1. #if !defined CS_PLAYER_SHARED_H
  2. #define CS_PLAYER_SHARED_H
  3. //
  4. // Configuration for using high priority entities by CS players
  5. //
  6. class CConfigurationForHighPriorityUseEntity_t
  7. {
  8. public:
  9. enum EPriority_t
  10. { // Priority of use entities, higher number is higher priority for use
  11. k_EPriority_Default,
  12. k_EPriority_Hostage,
  13. k_EPriority_Bomb
  14. };
  15. enum EPlayerUseType_t
  16. {
  17. k_EPlayerUseType_Start, // Player wants to initiate the use
  18. k_EPlayerUseType_Progress // Player wants to make progress using the entity
  19. };
  20. enum EDistanceCheckType_t
  21. {
  22. k_EDistanceCheckType_3D,
  23. k_EDistanceCheckType_2D
  24. };
  25. CBaseEntity *m_pEntity;
  26. EPriority_t m_ePriority;
  27. EDistanceCheckType_t m_eDistanceCheckType;
  28. Vector m_pos;
  29. float m_flMaxUseDistance;
  30. float m_flLosCheckDistance;
  31. float m_flDotCheckAngle;
  32. float m_flDotCheckAngleMax;
  33. public:
  34. // Check if this high priority use entity is better for use than the other one
  35. bool IsBetterForUseThan( CConfigurationForHighPriorityUseEntity_t const &other ) const;
  36. // Check if this entity can be used by the given player according to its use rules
  37. bool UseByPlayerNow( CCSPlayer *pPlayer, EPlayerUseType_t ePlayerUseType );
  38. };
  39. struct HalloweenMaskModelStruct
  40. {
  41. char* model;
  42. };
  43. static const HalloweenMaskModelStruct s_HalloweenMaskModels[] =
  44. {
  45. { "tf2" },
  46. { "models/player/holiday/facemasks/facemask_hoxton.mdl" },
  47. { "models/player/holiday/facemasks/porcelain_doll.mdl" },
  48. { "models/player/holiday/facemasks/facemask_skull.mdl" },
  49. { "models/player/holiday/facemasks/facemask_samurai.mdl" },
  50. { "models/player/holiday/facemasks/evil_clown.mdl" },
  51. { "tf2" },
  52. { "models/player/holiday/facemasks/facemask_wolf.mdl" },
  53. { "models/player/holiday/facemasks/facemask_sheep_model.mdl" },
  54. { "models/player/holiday/facemasks/facemask_bunny_gold.mdl" },
  55. { "models/player/holiday/facemasks/facemask_anaglyph.mdl" },
  56. { "models/player/holiday/facemasks/facemask_porcelain_doll_kabuki.mdl" },
  57. { "tf2" },
  58. { "models/player/holiday/facemasks/facemask_dallas.mdl" },
  59. { "models/player/holiday/facemasks/facemask_pumpkin.mdl" },
  60. { "models/player/holiday/facemasks/facemask_sheep_bloody.mdl" },
  61. { "models/player/holiday/facemasks/facemask_devil_plastic.mdl" },
  62. { "models/player/holiday/facemasks/facemask_boar.mdl" },
  63. { "tf2" },
  64. { "models/player/holiday/facemasks/facemask_chains.mdl" },
  65. { "models/player/holiday/facemasks/facemask_tiki.mdl" },
  66. { "models/player/holiday/facemasks/facemask_bunny.mdl" },
  67. { "models/player/holiday/facemasks/facemask_sheep_gold.mdl" },
  68. { "models/player/holiday/facemasks/facemask_zombie_fortune_plastic.mdl" },
  69. { "models/player/holiday/facemasks/facemask_chicken.mdl" },
  70. { "models/player/holiday/facemasks/facemask_skull_gold.mdl" },
  71. };
  72. static const HalloweenMaskModelStruct s_HalloweenMaskModelsCompetitive[] =
  73. {
  74. { "models/player/holiday/facemasks/facemask_samurai.mdl" },
  75. { "models/player/holiday/facemasks/facemask_boar.mdl" },
  76. { "models/player/holiday/facemasks/facemask_zombie_fortune_plastic.mdl" },
  77. { "models/player/holiday/facemasks/facemask_porcelain_doll_kabuki.mdl" },
  78. { "models/player/holiday/facemasks/facemask_pumpkin.mdl" },
  79. { "models/player/holiday/facemasks/facemask_hoxton.mdl" },
  80. { "models/player/holiday/facemasks/facemask_chains.mdl" },
  81. { "models/player/holiday/facemasks/evil_clown.mdl" },
  82. { "models/player/holiday/facemasks/facemask_dallas.mdl" },
  83. { "models/player/holiday/facemasks/facemask_wolf.mdl" },
  84. };
  85. static const HalloweenMaskModelStruct s_HalloweenMaskModelsTF2[] =
  86. {
  87. { "models/player/holiday/facemasks/facemask_tf2_demo_model.mdl" },
  88. { "models/player/holiday/facemasks/facemask_tf2_engi_model.mdl" },
  89. { "models/player/holiday/facemasks/facemask_tf2_heavy_model.mdl" },
  90. { "models/player/holiday/facemasks/facemask_tf2_medic_model.mdl" },
  91. { "models/player/holiday/facemasks/facemask_tf2_pyro_model.mdl" },
  92. { "models/player/holiday/facemasks/facemask_tf2_scout_model.mdl" },
  93. { "models/player/holiday/facemasks/facemask_tf2_sniper_model.mdl" },
  94. { "models/player/holiday/facemasks/facemask_tf2_soldier_model.mdl" },
  95. { "models/player/holiday/facemasks/facemask_tf2_spy_model.mdl" },
  96. };
  97. #endif // CS_PLAYER_SHARED_H