706
|
1 #include <assert.h>
|
|
2
|
|
3 #include "MM7.h"
|
|
4
|
|
5 #include "MapInfo.h"
|
|
6 #include "Game.h"
|
|
7 #include "GUIWindow.h"
|
|
8 #include "GUIFont.h"
|
|
9 #include "GUIProgressBar.h"
|
|
10 #include "Party.h"
|
|
11 #include "AudioPlayer.h"
|
|
12 #include "Outdoor.h"
|
|
13 #include "IndoorCamera.h"
|
|
14 #include "Overlays.h"
|
|
15 #include "Monsters.h"
|
|
16 #include "Arcomage.h"
|
|
17 #include "LOD.h"
|
|
18 #include "Actor.h"
|
|
19 #include "Allocator.h"
|
|
20 #include "Events.h"
|
|
21 #include "Viewport.h"
|
|
22 #include "FrameTableInc.h"
|
|
23 #include "Math.h"
|
|
24 #include "SpriteObject.h"
|
|
25 #include "ObjectList.h"
|
|
26 #include "Chest.h"
|
|
27 #include "PaletteManager.h"
|
|
28 #include "DecorationList.h"
|
|
29 #include "SaveLoad.h"
|
|
30 #include "stru123.h"
|
|
31 #include "Time.h"
|
|
32 #include "IconFrameTable.h"
|
|
33 #include "Awards.h"
|
|
34 #include "Autonotes.h"
|
|
35 #include "stru160.h"
|
|
36 #include "TurnEngine.h"
|
924
|
37 #include "CastSpellInfo.h"
|
706
|
38 #include "Weather.h"
|
|
39 #include "stru298.h"
|
|
40 #include "StorylineTextTable.h"
|
|
41 #include "Events2D.h"
|
|
42 #include "texts.h"
|
|
43
|
|
44 #include "mm7_data.h"
|
|
45
|
|
46
|
|
47
|
948
|
48
|
|
49 OptionsMenuSkin options_menu_skin; // 507C60
|
|
50
|
|
51
|
|
52
|
|
53
|
706
|
54 //----- (004142D3) --------------------------------------------------------
|
|
55 char __cdecl GameMenuUI_DrawKeyBindings()
|
|
56 {
|
|
57 unsigned int v0; // ebp@1
|
|
58 int v1; // ecx@2
|
|
59 unsigned int v2; // eax@6
|
|
60 GUIWindow *v3; // edx@6
|
|
61 signed int v4; // ecx@7
|
|
62 signed int v5; // eax@8
|
|
63 const char *v6; // ST0C_4@16
|
|
64 unsigned int v7; // eax@16
|
|
65 const char *v8; // ST0C_4@16
|
|
66 unsigned int v9; // eax@16
|
|
67 const char *v10; // ST0C_4@16
|
|
68 unsigned int v11; // eax@16
|
|
69 const char *v12; // ST0C_4@16
|
|
70 unsigned int v13; // eax@16
|
|
71 const char *v14; // ST0C_4@16
|
|
72 unsigned int v15; // eax@16
|
|
73 const char *v16; // ST0C_4@16
|
|
74 unsigned int v17; // eax@16
|
|
75 const char *v18; // ST0C_4@16
|
|
76 unsigned int v19; // eax@16
|
|
77 const char *v20; // ST0C_4@16
|
|
78 unsigned int v21; // eax@16
|
|
79 signed int v22; // ebp@16
|
|
80 const char *v23; // ST0C_4@16
|
|
81 unsigned int v24; // eax@16
|
|
82 const char *v25; // ST0C_4@16
|
|
83 unsigned int v26; // eax@16
|
|
84 const char *v27; // ST0C_4@16
|
|
85 unsigned int v28; // eax@16
|
|
86 const char *v29; // ST0C_4@16
|
|
87 unsigned int v30; // eax@16
|
|
88 const char *v31; // ST0C_4@16
|
|
89 unsigned int v32; // eax@16
|
|
90 const char *v33; // ST0C_4@17
|
|
91 unsigned int v34; // eax@17
|
|
92 const char *v35; // ST0C_4@17
|
|
93 unsigned int v36; // eax@17
|
|
94 const char *v37; // ST0C_4@17
|
|
95 unsigned int v38; // eax@17
|
|
96 const char *v39; // ST0C_4@17
|
|
97 unsigned int v40; // eax@17
|
|
98 const char *v41; // ST0C_4@17
|
|
99 unsigned int v42; // eax@17
|
|
100 const char *v43; // ST0C_4@17
|
|
101 unsigned int v44; // eax@17
|
|
102 const char *v45; // ST0C_4@17
|
|
103 unsigned int v46; // eax@17
|
|
104 const char *v47; // ST0C_4@17
|
|
105 unsigned int v48; // eax@17
|
|
106 const char *v49; // ST0C_4@17
|
|
107 unsigned int v50; // eax@17
|
|
108 const char *v51; // ST0C_4@17
|
|
109 unsigned int v52; // eax@17
|
|
110 const char *v53; // ST0C_4@17
|
|
111 unsigned int v54; // eax@17
|
|
112 const char *v55; // ST0C_4@17
|
|
113 unsigned int v56; // eax@17
|
|
114 const char *v57; // ST0C_4@17
|
|
115 unsigned int v58; // eax@17
|
|
116 unsigned int v59; // eax@18
|
948
|
117 //int v61; // [sp-14h] [bp-28h]@16
|
706
|
118 const char *v62; // [sp-10h] [bp-24h]@16
|
|
119 unsigned int a5; // [sp+10h] [bp-4h]@1
|
|
120
|
949
|
121 v0 = TargetColor(0xFFu, 0xFFu, 0xFFu);
|
706
|
122 a5 = v0;
|
|
123 if ( byte_4E28FC )
|
|
124 {
|
|
125 v1 = dword_507C0C + 15;
|
|
126 dword_507C0C = v1;
|
|
127 if ( v1 == 255 )
|
|
128 byte_4E28FC = 0;
|
|
129 }
|
|
130 else
|
|
131 {
|
|
132 v1 = dword_507C0C - 15;
|
|
133 dword_507C0C = v1;
|
|
134 if ( v1 == 15 )
|
|
135 byte_4E28FC = 1;
|
|
136 }
|
949
|
137 v2 = TargetColor(v1, 0, 0);
|
706
|
138 v3 = pGUIWindow_CurrentMenu;
|
|
139 dword_507C08 = v2;
|
|
140 if ( pGUIWindow_CurrentMenu->field_40 == 2 )
|
|
141 {
|
|
142 pPrevVirtualCidesMapping[dword_506E68] = pKeyActionMap->pPressedKeysBuffer[0];
|
|
143 memset(&KeyButtonFlagChangesArray, 0, sizeof(KeyButtonFlagChangesArray));
|
|
144 v4 = 0;
|
|
145 do
|
|
146 {
|
|
147 v5 = 0;
|
|
148 do
|
|
149 {
|
|
150 if ( v4 != v5 && pPrevVirtualCidesMapping[v4] == pPrevVirtualCidesMapping[v5] )
|
|
151 {
|
|
152 KeyButtonFlagChangesArray[v4] = 1;
|
|
153 KeyButtonFlagChangesArray[v5] = 1;
|
|
154 }
|
|
155 ++v5;
|
|
156 }
|
|
157 while ( v5 < 28 );
|
|
158 ++v4;
|
|
159 }
|
|
160 while ( v4 < 28 );
|
|
161 dword_506E68 = -1;
|
|
162 v3->field_40 = 0;
|
|
163 }
|
948
|
164 pRenderer->DrawTextureIndexed(8, 8, pIcons_LOD->GetTexture(uTextureID_Optkb[0]));
|
706
|
165 if ( KeyboardPageNum == 1 )
|
948
|
166 {
|
|
167 pRenderer->DrawTextureIndexed(0x13, 0x12E, pIcons_LOD->GetTexture(uTextureID_Optkb[3]));
|
|
168 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 142, v0, "Ш", 0, 0, 0);
|
706
|
169 v6 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[0]);
|
|
170 v7 = sub_414D24(0);
|
|
171 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 142, v7, v6, 0, 0, 0);
|
948
|
172 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 163, v0, "", 0, 0, 0);
|
706
|
173 v8 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[1]);
|
|
174 v9 = sub_414D24(1);
|
|
175 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 163, v9, v8, 0, 0, 0);
|
948
|
176 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 184, v0, "", 0, 0, 0);
|
706
|
177 v10 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[2]);
|
|
178 v11 = sub_414D24(2);
|
|
179 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 184, v11, v10, 0, 0, 0);
|
948
|
180 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 205, v0, "", 0, 0, 0);
|
706
|
181 v12 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[3]);
|
|
182 v13 = sub_414D24(3);
|
|
183 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 205, v13, v12, 0, 0, 0);
|
948
|
184 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 226, v0, "", 0, 0, 0);
|
706
|
185 v14 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[4]);
|
|
186 v15 = sub_414D24(4);
|
|
187 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 226, v15, v14, 0, 0, 0);
|
948
|
188 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 247, v0, "", 0, 0, 0);
|
706
|
189 v16 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[5]);
|
|
190 v17 = sub_414D24(5);
|
|
191 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 247, v17, v16, 0, 0, 0);
|
948
|
192 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 268, v0, ".", 0, 0, 0);
|
706
|
193 v18 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[6]);
|
|
194 v19 = sub_414D24(6);
|
|
195 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 268, v19, v18, 0, 0, 0);
|
948
|
196 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 142, v0, ". .", 0, 0, 0);
|
706
|
197 v20 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[7]);
|
|
198 v21 = sub_414D24(7);
|
|
199 v22 = 350;
|
|
200 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 142, v21, v20, 0, 0, 0);
|
948
|
201 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 163, a5, "", 0, 0, 0);
|
706
|
202 v23 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[8]);
|
|
203 v24 = sub_414D24(8);
|
|
204 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 163, v24, v23, 0, 0, 0);
|
948
|
205 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 184, a5, ".", 0, 0, 0);
|
706
|
206 v25 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[9]);
|
|
207 v26 = sub_414D24(9);
|
|
208 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 184, v26, v25, 0, 0, 0);
|
948
|
209 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 205, a5, ".", 0, 0, 0);
|
706
|
210 v27 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[10]);
|
|
211 v28 = sub_414D24(10);
|
|
212 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 205, v28, v27, 0, 0, 0);
|
948
|
213 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 226, a5, "", 0, 0, 0);
|
706
|
214 v29 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[11]);
|
|
215 v30 = sub_414D24(11);
|
|
216 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 226, v30, v29, 0, 0, 0);
|
948
|
217 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 247, a5, ". ", 0, 0, 0);
|
706
|
218 v31 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[12]);
|
|
219 v32 = sub_414D24(12);
|
|
220 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 247, v32, v31, 0, 0, 0);
|
948
|
221 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 268, a5, "", 0, 0, 0);
|
|
222
|
706
|
223 v62 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[13]);
|
948
|
224 v59 = sub_414D24(13);
|
706
|
225 }
|
|
226 else
|
|
227 {
|
948
|
228 pRenderer->DrawTextureIndexed(0x7F, 0x12E, pIcons_LOD->GetTexture(uTextureID_Optkb[4]));
|
|
229 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 142, v0, ". ", 0, 0, 0);
|
706
|
230 v33 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[14]);
|
|
231 v34 = sub_414D24(14);
|
|
232 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 142, v34, v33, 0, 0, 0);
|
948
|
233 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 163, v0, "", 0, 0, 0);
|
706
|
234 v35 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[15]);
|
|
235 v36 = sub_414D24(15);
|
|
236 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 163, v36, v35, 0, 0, 0);
|
948
|
237 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 184, v0, ". ", 0, 0, 0);
|
706
|
238 v37 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[16]);
|
|
239 v38 = sub_414D24(16);
|
|
240 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 184, v38, v37, 0, 0, 0);
|
948
|
241 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 205, v0, "", 0, 0, 0);
|
706
|
242 v39 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[17]);
|
|
243 v40 = sub_414D24(17);
|
|
244 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 205, v40, v39, 0, 0, 0);
|
948
|
245 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 226, v0, "", 0, 0, 0);
|
706
|
246 v41 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[18]);
|
|
247 v42 = sub_414D24(18);
|
|
248 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 226, v42, v41, 0, 0, 0);
|
948
|
249 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 247, v0, "", 0, 0, 0);
|
706
|
250 v43 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[19]);
|
|
251 v44 = sub_414D24(19);
|
|
252 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 247, v44, v43, 0, 0, 0);
|
948
|
253 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 23, 268, v0, ". ", 0, 0, 0);
|
706
|
254 v45 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[20]);
|
|
255 v46 = sub_414D24(20);
|
|
256 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 127, 268, v46, v45, 0, 0, 0);
|
948
|
257 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 142, v0, ". ", 0, 0, 0);
|
706
|
258 v47 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[21]);
|
|
259 v48 = sub_414D24(21);
|
|
260 v22 = 350;
|
|
261 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 142, v48, v47, 0, 0, 0);
|
948
|
262 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 163, a5, ". Ш", 0, 0, 0);
|
706
|
263 v49 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[22]);
|
|
264 v50 = sub_414D24(22);
|
|
265 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 163, v50, v49, 0, 0, 0);
|
948
|
266 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 184, a5, "", 0, 0, 0);
|
706
|
267 v51 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[23]);
|
|
268 v52 = sub_414D24(23);
|
|
269 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 184, v52, v51, 0, 0, 0);
|
948
|
270 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 205, a5, "", 0, 0, 0);
|
706
|
271 v53 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[24]);
|
|
272 v54 = sub_414D24(24);
|
|
273 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 205, v54, v53, 0, 0, 0);
|
948
|
274 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 226, a5, ". ", 0, 0, 0);
|
706
|
275 v55 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[25]);
|
|
276 v56 = sub_414D24(25);
|
|
277 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 226, v56, v55, 0, 0, 0);
|
948
|
278 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 247, a5, ". ", 0, 0, 0);
|
706
|
279 v57 = pKeyActionMap->GetVKeyDisplayName(pPrevVirtualCidesMapping[26]);
|
|
280 v58 = sub_414D24(26);
|
|
281 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 350, 247, v58, v57, 0, 0, 0);
|
948
|
282 pGUIWindow_CurrentMenu->DrawText(pFontLucida, 247, 268, a5, "", 0, 0, 0);
|
|
283
|
706
|
284 v62 = pKeyActionMap->GetVKeyDisplayName(pWindowList_at_506F50_minus1_indexing[0]);
|
948
|
285 v59 = sub_414D24(27);
|
706
|
286 }
|
948
|
287 return pGUIWindow_CurrentMenu->DrawText(pFontLucida, v22, 268, v59, v62, 0, 0, 0);
|
706
|
288 }
|
|
289
|
|
290
|
|
291 //----- (00414D24) --------------------------------------------------------
|
|
292 unsigned int __thiscall sub_414D24(int _this)
|
|
293 {
|
|
294 int v1; // esi@1
|
|
295 unsigned int v2; // edi@1
|
|
296 unsigned int v3; // ebx@1
|
|
297 unsigned int result; // eax@1
|
|
298
|
|
299 v1 = _this;
|
949
|
300 v2 = TargetColor(0xE1u, 0xCDu, 0x23u);
|
|
301 v3 = TargetColor(0xFu, 0, 0);
|
|
302 result = TargetColor(0xFFu, 0xFFu, 0xFFu);
|
706
|
303 if ( dword_506E68 == v1 )
|
|
304 {
|
|
305 if ( GetTickCount() % 0x3E8 <= 0x1F4 )
|
|
306 result = v3;
|
|
307 else
|
|
308 result = v2;
|
|
309 }
|
|
310 else
|
|
311 {
|
|
312 if ( KeyButtonFlagChangesArray[v1] )
|
|
313 result = dword_507C08;
|
|
314 }
|
|
315 return result;
|
|
316 }
|
|
317
|
|
318 //----- (00414D9A) --------------------------------------------------------
|
948
|
319 void GameMenuUI_DrawVideoOptions()
|
|
320 {
|
706
|
321 const char *v0; // ST0C_4@3
|
|
322 unsigned __int16 v1; // ax@3
|
948
|
323 //int v2; // eax@10
|
706
|
324 GUIWindow v3; // [sp+8h] [bp-54h]@3
|
|
325
|
948
|
326 pRenderer->DrawTextureIndexed(8, 8, pIcons_LOD->GetTexture(uTextureID_507C10));
|
706
|
327 if ( !pRenderer->bWindowMode && GammaController::IsGammaSupported() )
|
|
328 {
|
|
329 pRenderer->DrawTextureIndexed(
|
|
330 17 * uGammaPos + 42,
|
948
|
331 162,
|
|
332 pIcons_LOD->GetTexture(pTextureIDs_GammaPositions[uGammaPos]));
|
706
|
333 pRenderer->DrawTextureRGB(0x112u, 0xA9u, &stru_506E40);
|
|
334 v3.uFrameX = 22;
|
948
|
335 v0 = pGlobalTXT_LocalizationStrings[226]; // "Gamma controls the relative ""brightness"" of the game. May vary depending on your monitor."
|
706
|
336 v3.uFrameY = 190;
|
|
337 v3.uFrameWidth = 211;
|
|
338 v3.uFrameHeight = 79;
|
|
339 v3.uFrameZ = 232;
|
|
340 v3.uFrameW = 268;
|
949
|
341 v1 = TargetColor(0xFFu, 0xFFu, 0x9Bu);
|
706
|
342 v3.DrawTitleText(pFontSmallnum, 0, 0, v1, v0, 3u);
|
|
343 }
|
948
|
344
|
|
345 if (!pRenderer->pRenderD3D)
|
|
346 {
|
|
347 pRenderer->DrawTextureIndexed(20, 281, pIcons_LOD->GetTexture(uTextureID_507C50));
|
|
348 pRenderer->DrawTextureIndexed(20, 303, pIcons_LOD->GetTexture(uTextureID_507C54));
|
|
349 pRenderer->DrawTextureIndexed(20, 325, pIcons_LOD->GetTexture(uTextureID_507C58));
|
706
|
350 }
|
948
|
351 else
|
|
352 {
|
|
353 if (pGame->uFlags2 & GAME_FLAGS_2_DRAW_BLOODSPLATS)
|
|
354 pRenderer->DrawTextureIndexed(20, 281, pIcons_LOD->GetTexture(uTextureID_507C14));
|
|
355 if (pRenderer->bUseColoredLights)
|
|
356 pRenderer->DrawTextureIndexed(20, 303, pIcons_LOD->GetTexture(uTextureID_507C18));
|
|
357 if (pRenderer->bTinting)
|
|
358 pRenderer->DrawTextureIndexed(20, 325, pIcons_LOD->GetTexture(uTextureID_507C1C));
|
|
359 }
|
|
360 }
|
706
|
361
|
|
362
|
|
363
|
|
364 //----- (00414F82) --------------------------------------------------------
|
948
|
365 void DrawGameOptions()
|
|
366 {
|
|
367 pRenderer->DrawTextureIndexed(8, 8, pIcons_LOD->GetTexture(uTextureID_Options));
|
|
368 pRenderer->DrawTextureIndexed(8, 132, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_Background));
|
|
369
|
|
370 switch (uTurnSpeed)
|
|
371 {
|
|
372 default: pRenderer->DrawTextureIndexed(BtnTurnCoord[0], 270, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_TurnSpeed[0]));
|
|
373 case 64: pRenderer->DrawTextureIndexed(BtnTurnCoord[1], 270, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_TurnSpeed[1]));
|
|
374 case 128: pRenderer->DrawTextureIndexed(BtnTurnCoord[2], 270, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_TurnSpeed[2]));
|
|
375 }
|
|
376
|
|
377 if (bWalkSound) pRenderer->DrawTextureIndexed( 20, 303, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_WalkSound));
|
|
378 if (bShowDamage) pRenderer->DrawTextureIndexed(128, 303, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_ShowDamage));
|
|
379 if (bFlipOnExit) pRenderer->DrawTextureIndexed(128, 325, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_FlipOnExit));
|
|
380 if (bAlwaysRun) pRenderer->DrawTextureIndexed( 20, 325, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_AlwaysRun));
|
|
381
|
|
382 pRenderer->DrawTextureIndexed(265 + 17 * uSoundVolumeMultiplier, 162, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_SoundLevels[uSoundVolumeMultiplier]));
|
|
383 pRenderer->DrawTextureIndexed(265 + 17 * uMusicVolimeMultiplier, 216, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_SoundLevels[uMusicVolimeMultiplier]));
|
|
384 pRenderer->DrawTextureIndexed(265 + 17 * uVoicesVolumeMultiplier, 270, pIcons_LOD->GetTexture(options_menu_skin.uTextureID_SoundLevels[uVoicesVolumeMultiplier]));
|
|
385 }
|
|
386
|
|
387
|
|
388
|
|
389
|
|
390
|
|
391
|
|
392
|
|
393
|
|
394
|
706
|
395
|
948
|
396 OptionsMenuSkin::OptionsMenuSkin():
|
|
397 uTextureID_Background(0),
|
|
398 uTextureID_ArrowLeft(0),
|
|
399 uTextureID_ArrowRight(0),
|
|
400 uTextureID_unused_0(0), uTextureID_unused_1(0), uTextureID_unused_2(0),
|
|
401 uTextureID_FlipOnExit(0),
|
|
402 uTextureID_AlwaysRun(0),
|
|
403 uTextureID_WalkSound(0),
|
|
404 uTextureID_ShowDamage(0)
|
|
405 {
|
|
406 for (uint i = 0; i < 3; ++i) uTextureID_TurnSpeed[i] = 0;
|
|
407 for (uint i = 0; i < 10; ++i) uTextureID_SoundLevels[i] = 0;
|
|
408 }
|
|
409
|
|
410 void OptionsMenuSkin::Relaease()
|
|
411 {
|
|
412 #define RELEASE(id) \
|
|
413 {\
|
|
414 if (id)\
|
|
415 pIcons_LOD->GetTexture(id)->Release();\
|
|
416 id = 0;\
|
|
417 }
|
|
418
|
|
419 RELEASE(uTextureID_Background);
|
|
420 for (uint i = 0; i < 3; ++i)
|
|
421 RELEASE(uTextureID_TurnSpeed[i]);
|
|
422 RELEASE(uTextureID_ArrowLeft);
|
|
423 RELEASE(uTextureID_ArrowRight);
|
|
424 RELEASE(uTextureID_FlipOnExit);
|
|
425 for (uint i = 0; i < 10; ++i)
|
|
426 RELEASE(uTextureID_SoundLevels[i]);
|
|
427 RELEASE(uTextureID_AlwaysRun);
|
|
428 RELEASE(uTextureID_WalkSound);
|
|
429 RELEASE(uTextureID_ShowDamage);
|
|
430
|
|
431 #undef RELEASE
|
|
432 }
|