gdcnc.h 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. /*
  2. ** Command & Conquer Renegade(tm)
  3. ** Copyright 2025 Electronic Arts Inc.
  4. **
  5. ** This program is free software: you can redistribute it and/or modify
  6. ** it under the terms of the GNU General Public License as published by
  7. ** the Free Software Foundation, either version 3 of the License, or
  8. ** (at your option) any later version.
  9. **
  10. ** This program is distributed in the hope that it will be useful,
  11. ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ** GNU General Public License for more details.
  14. **
  15. ** You should have received a copy of the GNU General Public License
  16. ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. /***********************************************************************************************
  19. *** Confidential - Westwood Studios ***
  20. ***********************************************************************************************
  21. * *
  22. * Project Name : Commando *
  23. * *
  24. * $Archive:: /Commando/Code/Commando/gdcnc.h $*
  25. * *
  26. * $Author:: Tom_s $*
  27. * *
  28. * $Modtime:: 4/12/02 3:58p $*
  29. * *
  30. * $Revision:: 28 $*
  31. * *
  32. *---------------------------------------------------------------------------------------------*
  33. * Functions: *
  34. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  35. #ifndef GDCNC_H
  36. #define GDCNC_H
  37. #include "gamedata.h"
  38. #include "basecontroller.h"
  39. class cGameDataCnc : public cGameData {
  40. public:
  41. //////////////////////////////////////////////////////////////
  42. // Public constructors/destructors
  43. //////////////////////////////////////////////////////////////
  44. cGameDataCnc (void);
  45. ~cGameDataCnc (void);
  46. //////////////////////////////////////////////////////////////
  47. // Public operators
  48. //////////////////////////////////////////////////////////////
  49. cGameDataCnc & operator= (const cGameDataCnc &rhs);
  50. //////////////////////////////////////////////////////////////
  51. // Public constants
  52. //////////////////////////////////////////////////////////////
  53. enum {MAX_CREDITS = 999999};
  54. //////////////////////////////////////////////////////////////
  55. // Public methods
  56. //////////////////////////////////////////////////////////////
  57. virtual bool Is_Cnc(void) const {return true;}
  58. virtual cGameDataCnc * As_Cnc(void) {return this;}
  59. static const WCHAR* Get_Static_Game_Name(void);
  60. virtual void On_Game_Begin (void);
  61. virtual void On_Game_End (void);
  62. virtual void Soldier_Added (SoldierGameObj *soldier);
  63. virtual const WCHAR* Get_Game_Name(void) const {return this->Get_Static_Game_Name();}
  64. virtual GameTypeEnum Get_Game_Type(void) const {return GAME_TYPE_CNC;}
  65. virtual void Think(void);
  66. virtual void Load_From_Server_Config(void);
  67. virtual void Save_To_Server_Config(void);
  68. //virtual bool Is_Team_Game(void) const {return true;}
  69. // virtual int Choose_Player_Type(cPlayer* player, int team_choice, bool is_grunt) {return Choose_Player_Type(player, team_choice, is_grunt);}
  70. virtual bool Is_Game_Over(void);
  71. virtual void Export_Tier_2_Data(cPacket & packet);
  72. virtual void Import_Tier_2_Data(cPacket & packet);
  73. virtual void Show_Game_Settings_Limits(void);
  74. //virtual bool Is_Limited(void) const {return true;}
  75. virtual bool Is_Limited(void) const;
  76. //virtual bool Is_Editable_Reload_Map(void) const {return true;}
  77. //virtual bool Is_Editable_Max_Players(void) const {return true;}
  78. virtual bool Is_Editable_Teaming(void) const {return true;}
  79. virtual bool Is_Editable_Clan_Game(void) const {return true;}
  80. virtual bool Is_Editable_Friendly_Fire(void) const {return true;}
  81. virtual void Reset_Game(bool is_reloaded);
  82. virtual bool Is_Valid_Settings(WideStringClass& outMsg, bool check_as_server = false);
  83. virtual bool Is_Gameplay_Permitted(void);
  84. int Get_Starting_Credits(void) const {return StartingCredits;}
  85. void Set_Starting_Credits(int credits);
  86. void Show_My_Money(void);
  87. virtual void Get_Description(WideStringClass & description);
  88. cBoolean BaseDestructionEndsGame;
  89. cBoolean BeaconPlacementEndsGame;
  90. private:
  91. void Base_Destruction_Score_Tweaking(void);
  92. int StartingCredits;
  93. BaseControllerClass BaseGDI;
  94. BaseControllerClass BaseNOD;
  95. bool IsPlaying;
  96. };
  97. #endif // GDCNC_H