ScummVM API documentation
startrek.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11 
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16 
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef STARTREK_H
23 #define STARTREK_H
24 
25 #include "common/events.h"
26 #include "common/list.h"
27 #include "common/ptr.h"
28 #include "common/random.h"
29 #include "common/rect.h"
30 #include "common/scummsys.h"
31 #include "common/serializer.h"
32 #include "common/str.h"
33 #include "common/stream.h"
34 #include "common/system.h"
35 #include "common/util.h"
36 
37 #include "gui/saveload-dialog.h"
38 
39 #include "engines/engine.h"
40 
41 #include "math/cosinetables.h"
42 #include "math/sinetables.h"
43 
44 #include "startrek/action.h"
45 #include "startrek/awaymission.h"
46 #include "startrek/graphics.h"
47 #include "startrek/items.h"
48 #include "startrek/object.h"
49 #include "startrek/sound.h"
50 #include "startrek/space.h"
51 #include "startrek/detection.h"
52 
53 
54 using Common::SharedPtr;
55 using Common::String;
56 
57 namespace Common {
58 class MacResManager;
59 }
60 
61 namespace StarTrek {
62 
63 class StarTrekEngine;
64 class Room;
65 class Console;
66 class Resource;
67 
68 typedef String(StarTrekEngine::*TextGetterFunc)(int, uintptr, String *);
69 
70 const int SAVEGAME_DESCRIPTION_LEN = 30;
71 
73  uint32 version;
74  char description[SAVEGAME_DESCRIPTION_LEN + 1];
75 
76  uint32 saveDate;
77  uint16 saveTime;
78  byte saveTimeSecs;
79  uint32 playTime;
80 
81  ::Graphics::Surface *thumbnail;
82 
83  void setSaveTimeAndDate(TimeDate time) {
84  saveDate = ((time.tm_mday & 0xFF) << 24) | (((time.tm_mon + 1) & 0xFF) << 16) | ((time.tm_year + 1900) & 0xFFFF);
85  saveTime = ((time.tm_hour & 0xFF) << 8) | ((time.tm_min) & 0xFF);
86  saveTimeSecs = time.tm_sec & 0xFF;
87  }
88 
89  int getDay() {
90  return (saveDate >> 24) & 0xFF;
91  }
92  int getMonth() {
93  return (saveDate >> 16) & 0xFF;
94  }
95  int getYear() {
96  return saveDate & 0xFFFF;
97  }
98  int getHour() {
99  return (saveTime >> 8) & 0xFF;
100  }
101  int getMinute() {
102  return saveTime & 0xFF;
103  }
104 };
105 
106 
107 const int MAX_MENUBUTTONS = 32;
108 const int TEXTBOX_WIDTH = 26;
109 const int TEXT_CHARS_PER_LINE = TEXTBOX_WIDTH - 2;
110 const int MAX_TEXTBOX_LINES = 12;
111 
112 const int TEXT_INPUT_BUFFER_SIZE = 134;
113 const int MAX_TEXT_INPUT_LEN = 20;
114 
115 const int MAX_BUFFERED_WALK_ACTIONS = 32;
116 
117 const int MAX_BAN_FILES = 16;
118 
119 
120 
121 
122 enum kDebugLevels {
123  kDebugSound = 1 << 0,
124  kDebugGraphics = 1 << 1,
125  kDebugSavegame = 1 << 2,
126  kDebugSpace = 1 << 3,
127  kDebugGeneral = 1 << 4
128 };
129 
130 enum GameMode {
131  GAMEMODE_START = 0,
132  GAMEMODE_BRIDGE,
133  GAMEMODE_AWAYMISSION,
134  GAMEMODE_BEAMDOWN,
135  GAMEMODE_BEAMUP
136 };
137 
138 enum TextDisplayMode {
139  TEXTDISPLAY_WAIT = 0, // Wait for input before closing text
140  TEXTDISPLAY_SUBTITLES, // Automatically continue when speech is done
141  TEXTDISPLAY_NONE // No text displayed
142 };
143 
144 enum TextColor {
145  TEXTCOLOR_GREY = 0x88,
146  TEXTCOLOR_RED = 0xa1,
147  TEXTCOLOR_YELLOW = 0xb0,
148  TEXTCOLOR_BLUE = 0xc0
149 };
150 
151 // Keeps track of data for a list of buttons making up a menu
152 struct Menu {
153  Sprite sprites[MAX_MENUBUTTONS];
154  uint16 retvals[MAX_MENUBUTTONS];
155  uint32 disabledButtons;
156  uint16 numButtons;
157  int16 selectedButton;
158  Menu *nextMenu;
159 };
160 
161 // Special events that can be returned by handleMenuEvents.
162 // (Normally it returns the "retval" of a pressed button, which is positive.)
163 enum MenuEvent {
164  MENUEVENT_RCLICK_OFFBUTTON = -4,
165  MENUEVENT_ENABLEINPUT, // Makes buttons selectable (occurs after a delay)
166  MENUEVENT_RCLICK_ONBUTTON,
167  MENUEVENT_LCLICK_OFFBUTTON
168 };
169 
170 // Buttons for standard text display
171 enum TextButtons {
172  TEXTBUTTON_CONFIRM = 0,
173  TEXTBUTTON_SCROLLUP,
174  TEXTBUTTON_SCROLLDOWN,
175  TEXTBUTTON_PREVCHOICE,
176  TEXTBUTTON_NEXTCHOICE,
177  TEXTBUTTON_SCROLLUP_ONELINE,
178  TEXTBUTTON_SCROLLDOWN_ONELINE,
179  TEXTBUTTON_GOTO_TOP,
180  TEXTBUTTON_GOTO_BOTTOM,
181  TEXTBUTTON_SPEECH_DONE // "Virtual" button?
182 };
183 
184 // Buttons for option menu (corresponding to button indices, not button retvals, which are
185 // different for some reason)
186 enum OptionMenuButtons {
187  OPTIONBUTTON_TEXT,
188  OPTIONBUTTON_SAVE,
189  OPTIONBUTTON_LOAD,
190  OPTIONBUTTON_ENABLEMUSIC,
191  OPTIONBUTTON_DISABLEMUSIC,
192  OPTIONBUTTON_ENABLESFX,
193  OPTIONBUTTON_DISABLESFX,
194  OPTIONBUTTON_QUIT
195 };
196 
197 enum TrekEventType {
198  TREKEVENT_TICK = 0, // DOS clock changes
199  TREKEVENT_LBUTTONDOWN = 1,
200  TREKEVENT_MOUSEMOVE = 2,
201  TREKEVENT_LBUTTONUP = 3,
202  TREKEVENT_RBUTTONDOWN = 4,
203  TREKEVENT_RBUTTONUP = 5,
204  TREKEVENT_KEYDOWN = 6
205 };
206 
207 struct TrekEvent {
208  TrekEventType type;
209  Common::KeyState kbd;
210  Common::Point mouse;
211  uint32 tick;
212 };
213 
215  Common::String fileName;
216  Common::String topic;
217 };
218 
220  bool shields;
221  bool weapons;
222  bool underAttack;
223  bool inOrbit;
224  bool targetAnalysis;
225 
226  EnterpriseState() {
227  shields = false;
228  weapons = false;
229  underAttack = false;
230  inOrbit = false;
231  targetAnalysis = false;
232  }
233 };
234 
235 class Graphics;
236 class IWFile;
237 class Sound;
238 
239 class StarTrekEngine : public ::Engine {
240 protected:
241  // startrek.cpp
242 public:
243  StarTrekEngine(OSystem *syst, const StarTrekGameDescription *gamedesc);
244  ~StarTrekEngine() override;
245 
246  friend class Console;
247 
248  Common::Error run() override;
249  Common::Error runGameMode(int mode, bool resume);
250 
251  // Transporter room
252  void runTransportSequence(const Common::String &name);
253 
254  // Bridge
255  void initBridge(bool b);
256  void loadBridge();
257  void loadBridgeActors();
258  void cleanupBridge();
259  void runBridge();
260  void setBridgeMouseCursor();
261  void playBridgeSequence(int sequenceId);
262  void handleBridgeEvents();
263  void handleBridgeComputer();
264  void showMissionPerformance(int score, int missionScoreTextId, int missionId);
265 
266  int _bridgeSequenceToLoad;
267 
268 private:
269  Common::String getSpeechSampleForNumber(int number);
270  void showTextboxBridge(int talker, int textId);
271  void showTextboxBridge(int talker, Common::String text);
272  void showBridgeScreenTalkerWithMessage(int textId, Common::String talkerHeader, Common::String talkerId, bool removeTalker = true);
273  void showBridgeScreenTalkerWithMessages(Common::String texts[], Common::String talkerHeader, Common::String talkerId, bool removeTalker = true);
274  void showMissionStartEnterpriseFlyby(Common::String sequence, Common::String name);
275  void startBattle(Common::String enemyShip);
276  void wrongDestinationRandomEncounter();
277  void bridgeCrewAction(int crewId);
278  void contactTargetAction();
279  void orbitPlanetSequence(int sequenceId);
280  void negotiateWithElasiCereth();
281  void hailTheMasada();
282 
283  int16 _targetPlanet;
284  int16 _currentPlanet;
285  int _currentScreenTalker;
286  bool _gameIsPaused;
287  bool _hailedTarget;
288  int _deadMasadaPrisoners;
289  bool _beamDownAllowed;
290  int _missionEndFlag;
291  int16 _randomEncounterType; // 1: Klingon, 2: Romulan, 3: Elasi
292  int16 _lastMissionId;
293  int16 _missionPoints[7];
294 
295 public:
296  void playMovie(Common::String filename);
297  void playMovieMac(Common::String filename);
298 
299  uint16 getRandomWord();
300 
301  // awaymission.cpp
302  void initAwayMission();
303  void runAwayMission();
304  void cleanupAwayMission();
305  void loadRoom(const Common::String &missionName, int roomIndex);
306  void initAwayCrewPositions(int warpEntryIndex);
307  void handleAwayMissionEvents();
308  void awayMissionLeftClick();
313  void awayMissionSelectAction(bool openActionMenu);
314  void awayMissionUseObject(int16 clickedObject);
315  void awayMissionGetLookOrTalk(int16 clickedObject);
316  void unloadRoom();
321  int loadActorAnimWithRoomScaling(int actorIndex, const Common::String &animName, int16 x, int16 y);
322  Fixed8 getActorScaleAtPosition(int16 y);
323  void addAction(const Action &action);
324  void addAction(int8 type, byte b1, byte b2, byte b3);
325  void handleAwayMissionAction();
326 
327  void checkTouchedLoadingZone(int16 x, int16 y);
332  void updateAwayMissionTimers();
338  bool isPositionSolid(int16 x, int16 y);
339  void loadRoomIndex(int roomIndex, int spawnIndex);
340 
341  Room *getRoom();
342 
343  // intro.cpp
344 private:
345  void playIntro();
346  void showCreditsScreen(R3 *creditsBuffer, int index, bool deletePrevious = true);
351  void initIntroR3ObjectToMove(R3 *r3, int16 srcAngle, int16 srcDepth, int16 destAngle, int16 destDepth, int16 ticks);
352  void loadSubtitleSprite(int index, Sprite *sprite);
353 
354  // space.cpp (pseudo-3d)
355  void initStarfieldPosition();
356  void initStarfield(int16 x, int16 y, int16 width, int16 height, int16 arg8);
357  void addR3(R3 *r3);
358  void delR3(R3 *r3);
359  void clearStarfieldPixels();
360  void drawStarfield();
361  void updateStarfieldAndShips(bool arg0);
362  R3 *sub_19f24(R3 *r3);
363  void drawR3Shape(R3 *r3);
364  bool sub_1c022(R3 *r3);
365 
366  Point3 constructPoint3ForStarfield(int16 x, int16 y, int16 z);
367  Point3 matrixMult(const Matrix &weight, const Point3 &point);
368  Point3 matrixMult(const Point3 &point, const Matrix &weight);
369  int32 scaleSpacePosition(int32 x, int32 z);
370 
374  Matrix initMatrix();
375  Matrix initSpeedMatrixForXZMovement(Angle angle, const Matrix &matrix);
376 
377 
378  // actors.cpp (handles actors and animations)
379 public:
380  void initActors();
384  int loadActorAnim(int actorIndex, const Common::String &animName, int16 x, int16 y, Fixed8 scale);
385  void loadBanFile(const Common::String &name);
390  bool actorWalkToPosition(int actorIndex, const Common::String &animFile, int16 srcX, int16 srcY, int16 destX, int16 destY);
391  void updateActorAnimations();
392 
398  void renderBanBelowSprites();
399  void renderBan(byte *screenPixels, byte *bgPixels, int banFileIndex);
400  void renderBanAboveSprites();
401  void removeActorFromScreen(int actorIndex);
402  void removeDrawnActorsFromScreen();
403  void drawActorToScreen(Actor *actor, const Common::String &animName, int16 x, int16 y, Fixed8 scale, bool addSprite);
404  void releaseAnim(Actor *actor);
405  void initStandAnim(int actorIndex);
406  void updateActorPositionWhileWalking(Actor *actor, int16 x, int16 y);
411  void chooseActorDirectionForWalking(Actor *actor, int16 srcX, int16 srcY, int16 destX, int16 destY);
416  bool directPathExists(int16 srcX, int16 srcY, int16 destX, int16 destY);
417 
418  int findObjectAt(int x, int y);
419  int findObjectAt(Common::Point p) {
420  return findObjectAt(p.x, p.y);
421  }
425  Bitmap *loadAnimationFrame(const Common::String &filename, Fixed8 scale);
426 
432  int selectObjectForUseAction();
433  Common::String getCrewmanAnimFilename(int actorIndex, const Common::String &basename);
437  void updateMouseBitmap();
442  bool walkActiveObjectToHotspot();
446  bool isObjectUnusable(int objectIndex, int action);
450  void updateCrewmanGetupTimers();
451  void showInventoryIcons(bool showItem);
452  void hideInventoryIcons();
453  int showInventoryMenu(int x, int y, bool restoreMouse);
454  void initStarfieldSprite(Sprite *sprite, Bitmap *bitmap, const Common::Rect &rect);
455  Bitmap *scaleBitmap(Bitmap *bitmap, Fixed8 scale);
461  void scaleBitmapRow(byte *src, byte *dest, uint16 origWidth, uint16 scaledWidth);
462 
463  // events.cpp
464 public:
469  void pollEvents(bool queueEvents = true);
470  void waitForNextTick(bool queueEvents = true);
471  void initializeEventsAndMouse();
476  bool getNextEvent(TrekEvent *e, bool poll = true);
477  void removeNextEvent();
478  bool popNextEvent(TrekEvent *e, bool poll = true);
479  void addEventToQueue(const TrekEvent &e);
480 
481  Common::EventManager *getEventMan() {
482  return _eventMan;
483  }
484 
485 private:
486  Common::List<TrekEvent> _eventQueue;
487  bool _mouseMoveEventInQueue;
488  bool _tickEventInQueue;
489  uint32 _frameStartMillis;
490 
491 
492  // textbox.cpp
493 public:
498  const char *getNextTextLine(const char *text, char *line, int lineWidth);
503  void drawTextLineToBitmap(const char *text, int textLen, int x, int y, Bitmap *bitmap);
504 
505  Common::String centerTextboxHeader(Common::String headerText);
506  void getTextboxHeader(Common::String *headerTextOutput, Common::String speakerText, int choiceIndex);
512  Common::String readTextFromRdf(int choiceIndex, uintptr data, Common::String *headerTextOutput);
513 
517  void showTextbox(Common::String headerText, const Common::String &mainText, int xoffset, int yoffset, byte textColor, int maxTextLines); // TODO: better name. (return type?)
518 
519  Common::String skipTextAudioPrompt(const Common::String &str);
524  Common::String playTextAudio(const Common::String &str);
525 
530  int showText(TextGetterFunc textGetter, uintptr var, int xoffset, int yoffset, int textColor, bool loopChoices, int maxTextLines, bool rclickCancelsChoice);
531 
535  int getNumTextboxLines(const Common::String &str);
536  Common::String putTextIntoLines(const Common::String &text);
537 
541  TextBitmap *initTextSprite(int *xoffsetPtr, int *yoffsetPtr, byte textColor, int numTextLines, bool withHeader, Sprite *sprite);
545  void drawMainText(TextBitmap *bitmap, int numTextLines, int numTextboxLines, const Common::String &text, bool withHeader);
546 
547  Common::String readLineFormattedText(TextGetterFunc textGetter, uintptr var, int choiceIndex, TextBitmap *textBitmap, int numTextboxLines, int *numLines);
548 
553  Common::String readTextFromArray(int choiceIndex, uintptr data, Common::String *headerTextOutput);
558  String readTextFromArrayWithChoices(int choiceIndex, uintptr data, Common::String *headerTextOutput);
559  Common::String readTextFromFoundComputerTopics(int choiceIndex, uintptr data, Common::String *headerTextOutput);
560 
561  Common::String showCodeInputBox();
562  Common::String showComputerInputBox();
563  void redrawTextInput();
564  void addCharToTextInputBuffer(char c);
568  Common::String showTextInputBox(int16 arg0, int16 arg2, const Common::String &headerText);
569  void initTextInputSprite(int16 arg0, int16 arg2, const Common::String &headerText);
570  void cleanupTextInputSprite();
571 
572 private:
573  char _textInputBuffer[TEXT_INPUT_BUFFER_SIZE];
574  int16 _textInputCursorPos;
575  char _textInputCursorChar;
576  Sprite _textInputSprite;
577 
578  // menu.cpp
579 public:
583  int getMenuButtonAt(Sprite *sprites, int numSprites, int x, int y);
592  void chooseMousePositionFromSprites(Sprite *sprites, int numSprites, int spriteIndex, int mode);
597  void drawMenuButtonOutline(Bitmap *bitmap, byte color);
598  void showOptionsMenu(int x, int y);
599  void showBridgeMenu(Common::String menu, int x, int y);
600  void handleBridgeMenu(int menuEvent);
601  void showStarMap();
602  void orbitPlanet();
603  void captainsLog();
604 
608  int showActionMenu();
612  void loadMenuButtons(String mnuFilename, int xpos, int ypos);
616  void setVisibleMenuButtons(uint32 bits);
620  void disableMenuButtons(uint32 bits);
621  void enableMenuButtons(uint32 bits);
626  int handleMenuEvents(uint32 ticksUntilClickingEnabled, bool inTextbox);
627  void unloadMenuButtons();
628 
632  void chooseMouseBitmapForAction(int action, bool withRedOutline);
633  void showQuitGamePrompt(int x, int y);
634  void showGameOverMenu();
639  void showTextConfigurationMenu(bool fromOptionMenu);
640 
641  int loadTextDisplayMode();
642  void saveTextDisplayMode(int value);
643 
647  void showRepublicMap(int16 arg0, int16 turbolift);
651  int getRepublicMapAreaAtMouse();
656  int getRepublicMapAreaOrFailure(int16 turbolift);
657 
658 
659 private:
660  int16 _textDisplayMode;
661  uint32 _textboxVar2;
662  uint16 _textboxVar6;
663  bool _textboxHasMultipleChoices;
664  Menu *_activeMenu;
665  // Saved value of StarTrekEngine::_keyboardControlsMouse when menus are up
666  bool _keyboardControlsMouseOutsideMenu;
667 
668  // saveload.cpp
669 public:
670  bool showSaveMenu();
671  bool showLoadMenu();
672 
673  bool saveGame(int slot, Common::String desc);
674  bool loadGame(int slot);
675 
680  bool saveOrLoadGameData(Common::SeekableReadStream *in, Common::WriteStream *out, SavegameMetadata *meta);
681 
682  Common::String getSavegameFilename(int slotId) const;
683 
684  // detection.cpp
685 public:
686  const StarTrekGameDescription *_gameDescription;
687  uint32 getFeatures() const;
688  Common::Platform getPlatform() const;
689  uint8 getGameType() const;
690  Common::Language getLanguage() const;
691 
692  // _screenName = _missionName + _roomIndex
693  Common::String getScreenName() const {
694  return _missionName + (char)(_roomIndex + '0');
695  }
696 
697  // Variables
698 public:
699  int _gameMode;
700  int _lastGameMode;
701  bool _resetGameMode;
702 
703  // NOTE: this has a different meaning than the original game. When non-empty, a new
704  // room load is triggered, as opposed to original behaviour where this was only read
705  // when "loadRoom" was called.
706  Common::String _missionToLoad;
707  int _roomIndexToLoad;
708  int _spawnIndexToLoad;
709 
710  Common::String _missionName;
711  int _roomIndex;
713  Fixed16 _playerActorScale;
714 
715  // Queue of "actions" (ie. next frame, clicked on object) for away mission or bridge
716  Common::Queue<Action> _actionQueue;
717 
718  AwayMission _awayMission;
719  bool _warpHotspotsActive;
720  int16 _activeWarpHotspot;
721  int16 _activeDoorWarpHotspot;
722  int16 _lookActionBitmapIndex;
723 
724  Item _itemList[NUM_OBJECTS];
725 
726  Actor _actorList[NUM_ACTORS];
727  Actor *const _kirkActor;
728  Actor *const _spockActor;
729  Actor *const _mccoyActor;
730  Actor *const _redshirtActor;
731 
732  // ".BAN" files provide extra miscellaneous animations in the room, ie. flashing
733  // pixels on computer consoles, or fireflies in front of the screen.
734  Common::MemoryReadStreamEndian *_banFiles[MAX_BAN_FILES];
735  uint16 _banFileOffsets[MAX_BAN_FILES];
736 
737  Sprite _inventoryIconSprite;
738  Sprite _itemIconSprite;
739 
740  // Certain hotspots store a position value where objects must walk to before
741  // interacting with them. After calling "findObjectAt", these values are updated.
742  bool _objectHasWalkPosition;
743  Common::Point _objectWalkPosition;
744 
745  // Actions to perform after a crewman finishes walking to a position.
746  // Room-specific code can specify that a specific action of type
747  // "ACTION_FINISHED_WALKING" occurs after moving a crewman somewhere.
748  Action _actionOnWalkCompletion[MAX_BUFFERED_WALK_ACTIONS];
749  bool _actionOnWalkCompletionInUse[MAX_BUFFERED_WALK_ACTIONS];
750 
751  // _clockTicks is based on DOS interrupt 1A, AH=0; read system clock counter.
752  // Updates 18.206 times every second.
753  uint32 _clockTicks;
754  uint32 _frameIndex;
755  uint32 _roomFrameCounter; // Resets to 0 on loading a room
756 
757  bool _musicEnabled;
758  bool _sfxEnabled;
759  uint16 _word_467a6;
760  uint16 _musicWorking;
761  bool _sfxWorking;
762  bool _finishedPlayingSpeech;
763 
764  bool _mouseControllingShip;
765 
766  // TODO: make this work.
767  // When false, the keyboard generally acts in a more specific way (ie. move mouse
768  // between items in a menu).
769  bool _keyboardControlsMouse;
770 
771  bool _inQuitGameMenu;
772  bool _showSubtitles;
773 
774  byte _byte_45b3c;
775 
776  // Pseudo-3D / starfield stuff
777  Sprite _starfieldSprite;
778  Star _starList[NUM_STARS];
779  Point3 _starfieldPosition;
780  int32 _starfieldPointDivisor;
781  int16 _starfieldXVar1, _starfieldYVar1;
782  int16 _starfieldXVar2, _starfieldYVar2;
783  Common::Rect _starfieldRect;
784  R3 _enterpriseR3;
785  R3 *_r3List[NUM_SPACE_OBJECTS];
786  R3 *_orderedR3List[NUM_SPACE_OBJECTS];
787  Matrix _starPositionMatrix;
788  Matrix _someMatrix;
789  float _flt_50898;
790 
791  Graphics *_gfx;
792  Sound *_sound;
793  IWFile *_iwFile;
794  Resource *_resource;
795 
796  EnterpriseState _enterpriseState;
797 
798 private:
799  int leftClickEvent();
800  int rightClickEvent();
801  int mouseMoveEvent();
802  int lookupNextAction(const int *lookupArray, int action);
803  void loadBridgeComputerTopics();
804  void bridgeLeftClick();
805 
806  Common::RandomSource _randomSource;
807  Math::SineTable _sineTable;
808  Math::CosineTable _cosineTable;
809  Room *_room;
810  Common::List<ComputerTopic> _computerTopics;
811 };
812 
813 // Static function
814 bool saveOrLoadMetadata(Common::SeekableReadStream *in, Common::WriteStream *out, SavegameMetadata *meta);
815 
816 } // End of namespace StarTrek
817 
818 #endif
int tm_hour
Definition: system.h:109
Definition: system.h:106
Definition: str.h:59
Definition: surface.h:67
int tm_mday
Definition: system.h:110
Definition: stream.h:77
Definition: error.h:84
int tm_min
Definition: system.h:108
Definition: random.h:44
Definition: startrek.h:219
Definition: list.h:44
Definition: room.h:67
Definition: rect.h:144
Definition: stream.h:745
Definition: console.h:31
Definition: memstream.h:103
Definition: sprite.h:44
Definition: action.h:57
Definition: resource.h:54
Graphics::Surface * scale(const Graphics::Surface &srcImage, int xSize, int ySize)
Definition: items.h:103
Definition: iwfile.h:35
Definition: object.h:81
Definition: bitmap.h:31
Definition: startrek.h:214
int tm_sec
Definition: system.h:107
Definition: detection.h:39
Definition: algorithm.h:29
Definition: formatinfo.h:28
Definition: rect.h:45
Definition: action.h:27
Definition: startrek.h:72
int tm_year
Definition: system.h:112
Definition: awaymission.h:27
int16 x
Definition: rect.h:46
int tm_mon
Definition: system.h:111
int16 y
Definition: rect.h:47
Definition: keyboard.h:294
Definition: bitmap.h:55
Definition: space.h:144
Definition: system.h:161
Definition: ptr.h:159
Definition: startrek.h:239
Definition: startrek.h:152
Definition: startrek.h:207
Definition: events.h:472
Definition: engine.h:144
Definition: sound.h:53
Platform
Definition: platform.h:46
Definition: space.h:151
Language
Definition: language.h:45