27 #ifndef ICB_OPTIONS_MANAGER_PC_H_INCLUDED 28 #define ICB_OPTIONS_MANAGER_PC_H_INCLUDED 30 #include "engines/icb/p4.h" 31 #include "engines/icb/global_objects.h" 32 #include "engines/icb/global_switches.h" 33 #include "engines/icb/sound/fx_manager.h" 34 #include "engines/icb/sound/speech_manager.h" 35 #include "engines/icb/sound/music_manager.h" 36 #include "engines/icb/sound.h" 37 #include "engines/icb/direct_input.h" 42 extern MovieManager *g_personalSequenceManager;
44 #define MAX_BYTESIZE_OF_CREDITS_FILE (8 * 1024) 48 uint8 m_theData[MAX_BYTESIZE_OF_CREDITS_FILE];
50 int32 m_numberOfBytes;
54 int32 m_currentHeight;
58 uint32 m_logoSurfaceID;
62 uint32 m_movieSurfaceID;
64 bool8 m_movieBackdrop;
68 int32 m_totalMovieFrames;
72 void Initialise(
const char *textFileName,
const char *movieFileName, bool8 loopingMovie, bool8 attachLogo, int32 frameStart);
111 #define NUMBER_OF_IN_GAME_TOP_CHOICES 5 113 enum IN_GAME_TOP_CHOICES { CONTINUE = 0, SAVE_GAME = 1, LOAD_GAME = 2, OPTIONS = 3, QUIT = 4 };
115 #define NUMBER_OPTION_CHOICES 4 117 enum OPTION_CHOICES {
124 #define NUMBER_OF_AUDIO_CHOICES 4 133 #define NUMBER_OF_VIDEO_CHOICES 4 142 #define NUMBER_OF_CONTROL_CHOICES 2 144 enum CONTROL_CHOICES {
149 #define TOTAL_NUMBER_OF_GAME_SLOTS 100 150 #define NUMBER_OF_VISIBLE_GAME_SLOTS 4 151 #define NUMBER_OF_GAMESLOT_CHOICES 5 153 enum GAMESLOT_CHOICES {
161 #define NUMBER_OF_SAVECONFIRM_CHOICES 2 163 enum SAVECONFIRM_CHOICES { YEY = 0, NAY = 1 };
165 #define NUMBER_OF_QUIT_CHOICES 2 167 enum QUIT_CHOICES { YES = 0, NO = 1 };
169 #define NUMBER_OF_MAIN_TOP_CHOICES 5 171 enum MAIN_TOP_CHOICES {
178 #define NUMBER_OF_EXTRA_CHOICES 6 180 enum M_EXTRA_CHOICES {
189 #define NUMBER_OF_PLAYSELECT_CHOICES 10 191 enum M_PLAYSELECT_CHOICES {
204 #define TOTAL_NUMBER_OF_MOVIES 47 205 #define M_NUMBER_OF_VISIBLE_MOVIE_SLOTS 12 206 #define M_NUMBER_OF_MOVIE_CHOICES 13 208 enum M_MOVIE_CHOICES {
225 #define M_NUMBER_OF_PROFILE_CHOICES 11 227 enum M_PROFILES_CHOICES {
240 #define NUMBER_OF_GAMEOVER_CHOICES 3 242 enum GAMEOVER_CHOICES { RESTORE = 0, RESTART = 1, GAMEOVER = 2 };
244 #define MAX_LABEL_LENGTH 24 247 char label[MAX_LABEL_LENGTH];
248 uint32 secondsPlayed;
253 char filename[MAX_LABEL_LENGTH];
259 extern _MOVIESLOT g_movieLibrary[TOTAL_NUMBER_OF_MOVIES];
262 #define NORMALFONT 0x0000 263 #define SELECTEDFONT 0x0001 264 #define PALEFONT 0x0002 271 bool8 m_useDirtyRects;
274 bool8 m_thatsEnoughTa;
276 int32 m_autoAnimating;
277 int32 m_autoAnimating2;
279 int32 m_over_n_Frames;
285 int32 m_widthIncrements;
286 int32 m_bottomIncrements;
287 int32 m_topIncrements;
288 bool8 m_warpDirection;
290 char m_fontName[ENGINE_STRING_LEN];
292 uint32 *m_fontPalette;
295 _rgb m_selectedShade;
302 _SLOT *m_slots[TOTAL_NUMBER_OF_GAME_SLOTS];
304 uint32 m_movieOffset;
307 MAIN_TOP_CHOICES m_M_TOP_selected;
308 M_EXTRA_CHOICES m_M_EXTRA_selected;
309 M_MOVIE_CHOICES m_M_MOVIE_selected;
310 M_PLAYSELECT_CHOICES m_M_PLAYSELECT_selected;
311 M_PROFILES_CHOICES m_M_PROFILES_selected;
314 IN_GAME_TOP_CHOICES m_IG_TOP_selected;
317 OPTION_CHOICES m_OPTION_selected;
318 VIDEO_CHOICES m_VIDEO_selected;
319 AUDIO_CHOICES m_AUDIO_selected;
320 CONTROL_CHOICES m_CONTROL_selected;
321 GAMESLOT_CHOICES m_GAMESLOT_selected;
322 SAVECONFIRM_CHOICES m_SAVECONFIRM_selected;
323 QUIT_CHOICES m_QUIT_selected;
324 GAMEOVER_CHOICES m_GAMEOVER_selected;
327 uint32 m_myScreenSurfaceID;
328 uint32 m_mySlotSurface1ID;
329 uint32 m_thumbSurfaceIDs[8];
330 uint32 m_grayThumbSurfaceIDs[8];
331 uint32 m_movieSurfaceIDs[24];
332 uint32 m_grayMovieSurfaceIDs[24];
333 uint32 m_profileSurface;
340 bool8 m_alterLimiter;
341 bool8 m_choiceLimiter;
342 bool8 m_controlPage1;
343 uint32 m_controlAnimCursor;
345 int32 m_move_sfx_channel;
346 int32 m_choose_sfx_channel;
352 char m_editBuffer[MAX_LABEL_LENGTH];
353 char m_defaultSlotName[MAX_LABEL_LENGTH];
355 bool8 m_defaultWiper;
356 int32 m_emptySlotFlag;
363 LRECT m_slotBoundingRect;
364 int32 m_slotsAnimOffBy;
367 LRECT m_pageOff_from;
368 LRECT m_pageOff_dest;
369 bool8 m_letJoystickQuitEdit;
371 bool8 m_awaitingKeyPress;
372 bool8 m_configLimiter;
375 bool8 m_creditControl;
378 bool8 m_slideshowActive;
379 bool8 m_slideLimiter;
380 int32 m_currentSlide;
382 uint32 m_slideFillColour;
386 int32 m_profileScrollingOffset;
387 int32 m_profileScrollingLine;
388 bool8 m_lastLineDisplayed;
389 int32 m_profileScrolling;
396 void StartInGameOptions();
397 void StartMainOptions();
398 void StartGameOverOptions();
404 void ForceInGameScreenRefresh();
407 bool8 HasControl() {
return m_haveControl; }
411 void InitialiseScrollingText(
const char *textFileName,
const char *movieFileName, int32 frameStart);
412 void DoScrollingText();
413 void DisplayText(uint8 *ad, uint32 pitch,
const char *str, int32 x, int32 y, uint32 col, bool8 centredHorizontally, bool8 boxed = FALSE8);
414 const char *GetTextFromReference(uint32 hashRef);
415 uint32 CalculateStringWidth(
const char *str);
420 void CycleInGameOptionsLogic();
421 void CycleMainOptionsLogic();
422 void CycleGameOverLogic();
423 void InitialiseInGameOptions();
424 void MoveSelected(bool8 _down_);
425 void AlterSelected(bool8 _right_);
433 void MakeAllSurfii();
434 void KillAllSurfii();
436 void SetDrawColour(uint32 def);
437 void DrawRectangle(bool8 selected, uint32 x, uint32 y, uint32 width, uint32 height, uint8 *surface_address, uint32 pitch);
440 void SetDesiredOptionsBoxParameters(uint32 width, uint32 height, uint32 nFrames);
441 void SetTargetBox(uint32 x1, uint32 x2, uint32 y1, uint32 y2, uint32 nFrames);
442 bool8 AnimateThoseBrackets(bool8 forwards);
443 bool8 AnimateBracketsToBox(bool8 forwards, uint32 surface_id = working_buffer_id);
444 void AnimateSlotsPaging();
445 void GrabThumbnailImage();
446 void LoadVisibleThumbnails();
447 void LoadPagingThumbnails(uint32 slotOffset);
448 void MakeGrayScaleThumbnail(uint32 src_surface_id, uint32 dst_surface_id, uint32 w = 64, uint32 h = 48);
449 void LoadVisibleMovieShots();
450 void LoadPagingMovieShots(uint32 slotOffset);
451 void DrawWidescreenBorders();
452 void DrawPageIndicator(uint32 x, uint32 y, bool8 up, bool8 selected, uint8 *ad, uint32 pitch);
453 void FadeStrip(uint32 x, uint32 y, uint32 w, bool8 up, uint8 *ad, uint32 pitch);
456 void DrawMainOptionsScreen(uint32 surface_id);
457 void DrawInGameOptionsScreen();
458 void DrawGameOverScreen();
459 void DrawGameSlots(uint32 slotOffset, uint32 surface_id = working_buffer_id);
460 void DrawMovieSlots(uint32 offset, uint32 surface_id = working_buffer_id);
461 void DrawGameOptions();
462 void DrawAudioSettings();
463 void DrawVideoSettings();
464 void DrawControllerConfiguration();
465 void DrawMainLoadScreen(uint32 surface_id = working_buffer_id);
466 void DrawMovieScreen(uint32 surface_id = working_buffer_id);
467 void DrawQuitGameConfirmScreen(uint32 surface_id = working_buffer_id);
468 void DrawExtrasScreen(uint32 surface_id = working_buffer_id);
469 void DrawPlaySelectScreen(uint32 surface_id = working_buffer_id);
470 void DrawSlideShow();
471 void DrawProfileSelectScreen(uint32 surface_id = working_buffer_id);
472 void DrawProfileScreen(uint32 surface_id = working_buffer_id);
473 void DrawOverwriteSaveConfirmScreen(uint32 surface_id = working_buffer_id);
476 void InitialiseControlsScreen();
477 void InitialiseSlideShow();
478 void InitialiseAProfile();
481 void InitialiseSlots();
485 void EditSlotLabel();
487 void GetKeyAssignment();
490 void LoadBitmapFont();
491 void LoadGlobalTextFile();
492 bool8 SetCharacterSprite(
char c);
493 void RenderCharacter(uint8 *ad, uint32 pitch, int32 nX, int32 nY, uint32 col);
494 void GetCentredRectFotText(
const char *str,
LRECT &r, int32 height);
497 void InitialiseSounds();
502 void PlayMovie(uint32
id);
505 void LoadTitleScreenMovie();
506 void UnloadTitleScreenMovie();
Definition: options_manager_pc.h:252
Definition: px_common.h:109
Definition: options_manager_pc.h:246
Definition: px_bitmap_pc.h:44
Definition: px_bitmap_pc.h:51
Definition: px_linkeddatafile.h:53
Definition: options_manager_pc.h:266
Definition: px_types.h:32
Definition: options_manager_pc.h:46