Team Fortress 2 Source Code as on 22/4/2020
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.

81 lines
2.0 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //=============================================================================//
  7. #ifndef DODOVERVIEW_H
  8. #define DODOVERVIEW_H
  9. #include <mapoverview.h>
  10. #include "dod_shareddefs.h"
  11. #include "c_dod_basegrenade.h"
  12. class CDODMapOverview : public CMapOverview
  13. {
  14. DECLARE_CLASS_SIMPLE( CDODMapOverview, CMapOverview );
  15. CDODMapOverview( const char *pElementName );
  16. int m_CameraIcons[MAX_TEAMS];
  17. int m_CapturePoints[MAX_CONTROL_POINTS];
  18. void ShowLargeMap( void );
  19. void HideLargeMap( void );
  20. void ToggleZoom( void );
  21. void AddGrenade( C_DODBaseGrenade *pGrenade );
  22. void RemoveGrenade( C_DODBaseGrenade *pGrenade );
  23. void PlayerChat( int index );
  24. void DrawQuad( Vector pos, int scale, float angle, int textureID, int alpha );
  25. void DrawBombTimerSwipeIcon( Vector pos, int scale, int textureID, float flPercentRemaining );
  26. void DrawHorizontalSwipe( Vector pos, int scale, int textureID, float flCapPercentage, bool bSwipeLeft );
  27. bool DrawCapturePoint( int iCP, MapObject_t *obj );
  28. virtual void VidInit( void );
  29. virtual bool IsVisible( void );
  30. protected:
  31. virtual void SetMode(int mode);
  32. virtual void InitTeamColorsAndIcons();
  33. virtual void FireGameEvent( IGameEvent *event );
  34. virtual void DrawCamera();
  35. virtual void DrawMapPlayers();
  36. virtual void Update();
  37. virtual void UpdateSizeAndPosition();
  38. // rules that define if you can see a player on the overview or not
  39. virtual bool CanPlayerBeSeen(MapPlayer_t *player);
  40. void DrawVoiceIconForPlayer( int playerIndex );
  41. virtual bool DrawIcon( MapObject_t *obj );
  42. protected:
  43. void UpdateCapturePoints();
  44. private:
  45. int m_iLastMode;
  46. CUtlVector<MapObject_t> m_Grenades;
  47. int m_iVoiceIcon;
  48. int m_iChatIcon;
  49. float m_flPlayerChatTime[MAX_PLAYERS];
  50. CHudTexture *m_pC4Icon;
  51. CHudTexture *m_pExplodedIcon;
  52. CHudTexture *m_pC4PlantedBG;
  53. CHudTexture *m_pIconDefended;
  54. #define DOD_MAP_ZOOM_LEVELS 2
  55. };
  56. extern CDODMapOverview *GetDODOverview( void );
  57. #endif // DODOVERVIEW_H