OPTIONS.H 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. /*
  2. ** Command & Conquer Red Alert(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. /* $Header: /CounterStrike/OPTIONS.H 1 3/03/97 10:25a Joe_bostic $ */
  19. /***********************************************************************************************
  20. *** C O N F I D E N T I A L --- W E S T W O O D S T U D I O S ***
  21. ***********************************************************************************************
  22. * *
  23. * Project Name : Command & Conquer *
  24. * *
  25. * File Name : OPTIONS.H *
  26. * *
  27. * Programmer : Joe L. Bostic *
  28. * *
  29. * Start Date : June 8, 1994 *
  30. * *
  31. * Last Update : June 8, 1994 [JLB] *
  32. * *
  33. *---------------------------------------------------------------------------------------------*
  34. * Functions: *
  35. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  36. #ifndef OPTIONS_H
  37. #define OPTIONS_H
  38. class OptionsClass {
  39. public:
  40. enum {
  41. MAX_SCROLL_SETTING=7,
  42. MAX_SPEED_SETTING=7
  43. };
  44. OptionsClass(void);
  45. void One_Time(void);
  46. void Process(void);
  47. void Fixup_Palette(void) const;
  48. void Set_Shuffle(int on);
  49. void Set_Repeat(int on);
  50. void Set_Score_Volume(fixed volume, bool feedback);
  51. void Set_Sound_Volume(fixed volume, bool feedback);
  52. void Set_Brightness(fixed brightness);
  53. fixed Get_Brightness(void) const;
  54. void Set_Saturation(fixed color);
  55. fixed Get_Saturation(void) const;
  56. void Set_Contrast(fixed contrast);
  57. fixed Get_Contrast(void) const;
  58. void Set_Tint(fixed tint);
  59. fixed Get_Tint(void) const;
  60. int Normalize_Delay(int delay) const;
  61. int Normalize_Volume(int volume) const;
  62. /*
  63. ** File I/O routines
  64. */
  65. void Load_Settings(void);
  66. void Save_Settings(void);
  67. void Set(void);
  68. /*
  69. ** This is actually the delay between game frames expressed as 1/60 of
  70. ** a second. The default value is 4 (1/15 second).
  71. */
  72. unsigned int GameSpeed;
  73. int ScrollRate; // Distance to scroll.
  74. fixed Volume; // Volume for sound effects.
  75. fixed ScoreVolume; // Volume for scores.
  76. #ifdef FIXIT_VERSION_3
  77. fixed MultiScoreVolume; // Volume for scores during multiplayer games.
  78. #endif
  79. fixed Brightness; // Brightness.
  80. fixed Tint; // Hue
  81. fixed Saturation; // Saturation
  82. fixed Contrast; // Value
  83. unsigned AutoScroll:1; // Does map autoscroll?
  84. unsigned IsScoreRepeat:1; // Score should repeat?
  85. unsigned IsScoreShuffle:1; // Score list should shuffle?
  86. unsigned IsPaletteScroll:1;// Allow palette scrolling?
  87. /*
  88. ** These are the hotkeys used for keyboard control.
  89. */
  90. KeyNumType KeyForceMove1;
  91. KeyNumType KeyForceMove2;
  92. KeyNumType KeyForceAttack1;
  93. KeyNumType KeyForceAttack2;
  94. KeyNumType KeySelect1;
  95. KeyNumType KeySelect2;
  96. KeyNumType KeyScatter;
  97. KeyNumType KeyStop;
  98. KeyNumType KeyGuard;
  99. KeyNumType KeyNext;
  100. KeyNumType KeyPrevious;
  101. KeyNumType KeyFormation;
  102. KeyNumType KeyHome1;
  103. KeyNumType KeyHome2;
  104. KeyNumType KeyBase;
  105. KeyNumType KeyResign;
  106. KeyNumType KeyAlliance;
  107. KeyNumType KeyBookmark1;
  108. KeyNumType KeyBookmark2;
  109. KeyNumType KeyBookmark3;
  110. KeyNumType KeyBookmark4;
  111. KeyNumType KeySelectView;
  112. KeyNumType KeyRepair;
  113. KeyNumType KeyRepairOn;
  114. KeyNumType KeyRepairOff;
  115. KeyNumType KeySell;
  116. KeyNumType KeySellOn;
  117. KeyNumType KeySellOff;
  118. KeyNumType KeyMap;
  119. KeyNumType KeySidebarUp;
  120. KeyNumType KeySidebarDown;
  121. KeyNumType KeyOption1;
  122. KeyNumType KeyOption2;
  123. KeyNumType KeyScrollLeft;
  124. KeyNumType KeyScrollRight;
  125. KeyNumType KeyScrollUp;
  126. KeyNumType KeyScrollDown;
  127. KeyNumType KeyQueueMove1;
  128. KeyNumType KeyQueueMove2;
  129. KeyNumType KeyTeam1;
  130. KeyNumType KeyTeam2;
  131. KeyNumType KeyTeam3;
  132. KeyNumType KeyTeam4;
  133. KeyNumType KeyTeam5;
  134. KeyNumType KeyTeam6;
  135. KeyNumType KeyTeam7;
  136. KeyNumType KeyTeam8;
  137. KeyNumType KeyTeam9;
  138. KeyNumType KeyTeam10;
  139. void Adjust_Palette(PaletteClass const & oldpal, PaletteClass & newpal, fixed brightness, fixed color, fixed tint, fixed contrast) const;
  140. protected:
  141. private:
  142. static char const * const HotkeyName;
  143. };
  144. #endif