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.6 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. // tf_tactical_mission.h
  3. // Team Fortress specific missions
  4. // Michael Booth, July 2009
  5. #ifndef TF_TACTICAL_MISSION_H
  6. #define TF_TACTICAL_MISSION_H
  7. #include "tactical_mission.h"
  8. #include "team_control_point_master.h"
  9. #include "fmtstr.h"
  10. class CTFDefendSetupGatesDeployZone : public CTacticalMissionZone
  11. {
  12. public:
  13. };
  14. class CTFDefendSetupGatesMission : public CTacticalMission
  15. {
  16. public:
  17. CTFDefendSetupGatesMission( void );
  18. virtual const CTacticalMissionZone *GetDeployZone( CBasePlayer *who ) const; // where give player should be during this mission
  19. virtual const CTacticalMissionZone *GetObjectiveZone( void ) const; // control points, setup gates, sections of cart path, etc.
  20. virtual const CTacticalMissionZone *GetEnemyZone( void ) const; // where we expect enemies to be during this mission
  21. virtual const char *GetName( void ) const { return "DefendSetupGates"; } // return name of this mission
  22. };
  23. //---------------------------------------------------------------------------------------------
  24. class CTFDefendPointZone : public CTacticalMissionZone
  25. {
  26. public:
  27. CTFDefendPointZone( CTeamControlPoint *point );
  28. };
  29. class CTFDefendPointSniperZone : public CTacticalMissionZone
  30. {
  31. public:
  32. CTFDefendPointSniperZone( CTeamControlPoint *point );
  33. virtual ~CTFDefendPointSniperZone( void ){}
  34. };
  35. class CTFDefendPointMission : public CTacticalMission
  36. {
  37. public:
  38. CTFDefendPointMission( CTeamControlPoint *point );
  39. ~CTFDefendPointMission( void );
  40. virtual const CTacticalMissionZone *GetDeployZone( CBasePlayer *who ) const; // where give player should be during this mission
  41. virtual const CTacticalMissionZone *GetObjectiveZone( void ) const; // control points, setup gates, sections of cart path, etc.
  42. virtual const CTacticalMissionZone *GetEnemyZone( void ) const; // where we expect enemies to be during this mission
  43. virtual const char *GetName( void ) const { return m_name; } // return name of this mission
  44. private:
  45. CTeamControlPoint *m_point;
  46. CTFDefendPointZone *m_defenseZone;
  47. CTFDefendPointSniperZone *m_sniperZone;
  48. CFmtStrN< 32 > m_name;
  49. };
  50. //---------------------------------------------------------------------------------------------
  51. /**
  52. * The mission manager provides access to all available missions
  53. */
  54. class CTFTacticalMissionManager : public CTacticalMissionManager
  55. {
  56. public:
  57. virtual void OnServerActivate( void ); // Invoked when server loads a new map, after everything has been created/spawned
  58. virtual void OnRoundRestart( void ); // invoked when a game round restarts
  59. };
  60. #endif // TF_TACTICAL_MISSION_H